Digital signal coding and decoding methods and apparatuses and programs therefor

ABSTRACT

At the coder side, bits of samples of each frame of an input digital signal are concatenated every digit common to the samples across each frame to generate equi-order bit sequences, which are output as packets. At the decoding side, the input equi-order sequences are arranged inversely to their arrangement at the coder side to reconstruct sample sequences. When a packet dropout occurs, a missing information compensating part  430  correct the reconstructed sample sequences in a manner to reduce an error between the spectral envelope of the reconstructed sample sequence concerned and a known spectral envelope.

BACKGROUND OF THE INVENTION

[0001] The present invention relates to coding and decoding methods forreducing the number of bits that represent various digital signals suchas an acoustic signal and an image signal and apparatuses and programstherefor, particularly, to those capable of controlling allowabledistortion.

[0002] To compress audio and visual information, there are proposed anirreversible distortion-prone or lossy coding scheme, and adistortion-free or lossless coding scheme. For irreversible compressioncoding (or lossy compression coding), there are several well knownschemes such as ITU-T (International Telecommunications Union-TelecomStandardization) and ISO/IEC MPEG (International Organization forStandardization/International Electrotechnical Commission Moving PictureExperts Group) standard schemes. With these irreversible compressioncoding schemes, it is possible to compress the original digital signaldown to {fraction (1/10)} or less with a little loss of signal data.However, the loss depends on the coding condition or the input signal,and may sometimes lead to degradation of the reconstructed signal.

[0003] On the other hand, a known reversible compression coding (orlossless compression coding) scheme capable of completely reconstructingthe original signal is a universal compression coding scheme for tocompressing data files and texts of computers. This compression codingscheme is able to compress any type of signals while learning thestatistics of the input sequence; tests or the like can be compresseddown to approximately ½, but in the case of audio and visual data, theircompression ratio is only about 20%.

[0004] A combination use of high-compression-ratio irreversible codingand reversible compression of an error between the reconstructed and theoriginal signal, flexible use either the high-compression-ratioirreversible coding or allows the reversible compression coding asrequired.

[0005] The inventor of the present application has proposed the abovecombined compression coding scheme in Japanese Patent ApplicationLaid-Open Gazette No. 44847/01 “Coding Method, Decoding Method andApparatuses Therefor and Recording Media Having Recorded ThereonPrograms Therefor.” While described in detail in the above gazette, thecombined compression coding scheme will be described below in brief withreference to FIG. 1.

[0006] In a coder 10, a digital input signal (hereinafter referred toalso as an input signal sample sequence) is input via an input terminal100, and in a frame separation part 100 the input signal sample sequenceis separated into frames each consisting of, for example, 1024 inputsignal samples.

[0007] In an irreversible quantization part 120 the output from theframe forming part 110 is subjected to irreversible compression coding.This coding may be of any scheme suited to the digital input signal aslong as it enables the input signal to be reconstructed to some extentwhen it is decoded. For example, when the input signal is a speechsignal, ITU-T speech coding or the like can be used; in the case ofmusic, MPEG or Twin VQ (Transform-Domain Weighted Interleaved VectorQuantization) can be used; and in the case of video, MPEG or the likecan be used. Further, various irreversible quantization schemesmentioned in the above-mentioned Japanese gazette can also be employed.Incidentally, the output from the irreversible quantization part 120will hereinafter be referred to as an “irreversibly compressed codeI(n).”

[0008] In an inverse quantization part 130 of the same configuration asthat of a decoding part (i.e. an inverse quantization part 230)corresponding to the irreversible quantization part 120, a locallyreconstructed signal is generated from the irreversibly compressed codeI(n). An error signal between the locally reconstructed signal and theoriginal digital input signal is calculated in a subtraction part 140.Usually the amplitude of the error signal is appreciably smaller thanthe amplitude of the original digital input signal. Accordingly, ascompared with reversibly compression coding of the digital input signalas it is, reversible compression coding of the error signal permitsreduction of the amount of information.

[0009] To increase the efficiency of the reversible compression coding,a rearrangement part 160 rearranges bits of the error signal (i.e. a bitsequence or stream). The details of processing by the rearrangement part160 will be described below with reference to FIG. 2. In the digitalinput signal (FIG. 2A) a positive or negative integer of each samplevalue (amplitude) is represented using a 2's complement format. Errorsignal samples between the digital input signal and the correspondinglocally reconstructed signal are shown in FIG. 2B. The rearrangementpart 160 converts the error signal (that is, a bit sequence) from a bitsequence of the 2's complement format to a bit sequence of asign-magnitude format (a binary number of sign and magnitude) (FIG. 2C).In the converted error signal, MSB (Most Significant Bit) to a secondLSB (Least Significant Bit) represent the magnitude of its amplitude andLSB the sign of the amplitude.

[0010] Next, in the rearrangement part 160 the error signal samplesconverted to the sign-magnitude format are combined at their respectivecorresponding bit positions (i.e., MSB, second MSB, . . . , LSB),successively in a temporal order in FIG. 2 (FIG. 2D). Each of these bitsequences (e.g., consisting of 1024 bits at the same bit position) willhereinafter be referred to as a “equi-position bit sequence.” In theabove rearrangement the value of each error signal remains unchanged.Since the error signal is small in amplitude, however, high-order bitsall become “0s” frequently. As a result, a sequence of “0s” providesenhanced efficiency in the reversible compression coding of the errorsignal.

[0011] Next, the output from the rearrangement part 160 is subjected toreversible compression coding in a reversible coding part 150. Thereversible coding part 150 performs the reversible compression coding ofthe equi-position bit sequences by entropy coding which utilizes, forexample, the presence of a consecutive sequence or a frequent-occurrencesequence, such as Huffman coding or arithmetic coding, the codedequi-position bit sequences being provided to a decoder 20. Thecompression efficiency will be increased as well by applying to theoutput from the rearrangement part 160 universal coding that reversiblycompresses a text or the like.

[0012] As the result of the above processing, the coder 10 outputs theirreversibly compressed code I(n) from the irreversible quantizationpart 120 and the reversibly compressed code I(e) from the reversiblecoding part 150.

[0013] In the decoder 20 a decoding part 210 decodes the reversiblycompressed code I(e). And a rearrangement part 220 sequentially outputsthe error signals for each frame by performing processing reverse tothat of the rearrangement part 160. The inverse quantization part 230decodes the irreversibly compressed code I(n). An addition part 240 addsthe outputs from the inverse quantization part 230 and the rearrangementpart 160. Finally, a frame combining part 250 sequentially outputs theoutput signal from the addition part 240 to reconstruct the originalinput signal sample sequence, which is provided at an output terminal260.

[0014] The conventional reversible compressing coding scheme presents aproblem that when a bit erasure occurs during transmission, each sampleto be reconstructed by the rearrangement part of the decoder 20 getsmixed with bits of other samples, seriously degrading the reconstructedsignal quality. This prior art scheme provides a compression ratio ofapproximately ½ at the highest and cannot achieve a ⅓ or ¼ compressionratio with no substantial deterioration of quality nor can it implementcompression with a satisfactory accuracy.

[0015] Moreover, even if the number of bits of the digital valuerepresenting the amplitude of the original signal is reduced by one bit,it is possible to restore the original waveform with the same accuracyas that with no bit reduction, but reducing four or more bits raises anauditory-sensation problem that high quantization noise is noticeable.

SUMMARY OF THE INVENTION

[0016] It is therefore an object of the present invention to providecoding and decoding methods which prevent a bit erasure duringtransmission from leading to serious degradation of the decoded signalquality and apparatuses which embody the methods.

[0017] A coding method according to the present invention comprises thesteps of:

[0018] (a) generating multiple sets of data either consisting ofmultiple sets of lossless data of bits over said samples at each one ofbit positions of said digital signal in said frame or consisting oflossy data and lossless data of an error signal due to said lossy data;and

[0019] (b) coding said multiple sets of data to produce codes.

[0020] A decoding method according to the present invention comprisedthe steps of:

[0021] (a) decoding input codes to produce multiple sets of data eitherconsisting of multiple sets of lossless data of bits over said samplesat each one of bit positions of said digital signal in said frame orconsisting of lossy data and lossless data of an error signal due to thelossy data; and

[0022] (b) reconstructing a digital signal based on said multiple setsof data.

[0023] A coder for coding a digital signal for each frame according tothe present invention comprises:

[0024] means for generating multiple sets of data either consisting ofmultiple sets of lossless data of bits over said samples at each one ofbit positions of said digital signal in said frame or consisting oflossy data and lossless data of an error signal due to said lossy; and

[0025] means for coding said multiple sets of data to produce codes.

[0026] A decoder which reconstructs a sequence of samples of a digitalsignal for each frame according to the present invention comprises:

[0027] means for decoding input codes to produce multiple sets of dataeither consisting of multiple sets of lossless data of bits over saidsamples at each one of bit positions of said digital signal in saidframe or consisting of lossy data and lossless data of an error signaldue to the lossy data; and

[0028] means for reconstructing a digital signal based on said multiplesets of data.

[0029] According to the coding method of the present invention, eachpiece of transmission/recording unit data is put in packet form, andhence, even if the amount of information is reduced by intentionallyerasing the packet in accordance with the channel capacity or storagecapacity during coding, the decoding method of the present inventionenables the transmission/recording unit data to be compensated for thepacket erasure.

[0030] In this specification, the packet erasure refers to the cases:where all packets of one frame are not input to the decoder because ofintentionally removing packets of one frame so as to control the amountof information; where a packet erasure occurs because a router or thelike does not send out some packets due to traffic congestion in acommunication network or due to transmission line failure or abnormalityof a recording/playback unit; and where because of an error in the inputpacket the transmission/recording unit data concerned cannot be decodednor can it be used.

BRIEF DESCRIPTIN OF THE DRAWINGS

[0031]FIG. 1 is a block diagram illustrating functional configurationsof a coder and a decoder in the prior art

[0032]FIGS. 2A to 2D are diagrams for explaining processing of arearrangement part 160 in FIG. 1;

[0033]FIG. 3 is a block diagram illustrating the functionalconfiguration of a coder and a decoder according to Embodiment 1 of thepresent invention;

[0034]FIG. 4A is a diagram showing an example of processing of therearrangement part 160;

[0035]FIG. 4B is a diagram showing an example of the format of a packet;

[0036]FIG. 5 is a graph showing an example of comparison between theoriginal sound and a distortion component in association with processingby a missing information compensating correcting part 430;

[0037]FIG. 6 is a block diagram illustrating functional configurationsof a coder and a decoder according to Embodiment 2 of the presentinvention;

[0038]FIG. 7 is a flowchart showing an example of a procedure by themissing information compensating part 430 in the case of using auxiliaryinformation;

[0039]FIG. 8 is a block diagram corresponding to FIG. 7, depicting anexample of the functional configuration of the missing informationcompensating part 430;

[0040]FIG. 9 is a flowchart showing another example of the procedure bythe missing information compensating part 430 in the case of usingauxiliary information;

[0041]FIG. 10 is a block diagram illustrating the functionalconfiguration of a concrete example of a composite spectral envelopecalculating part 437;

[0042]FIG. 11 is a block diagram illustrating a coder and a decoderaccording to Embodiment 3 of the present invention;

[0043]FIG. 12 is a block diagram illustrating a modified form of thedecoder according to Embodiment 3;

[0044]FIG. 13A is a graph showing SNR of a decoded signal according tocomputer simulation for explaining the effect of the present invention;

[0045]FIG. 13B is a graph showing cepstrum distance between a decodedsignal and an original signal according to computer simulation forexplaining the effect of the present invention;

[0046]FIG. 14 is a block diagram illustrating a coder and a decoderaccording to Embodiment 4 of the present invention;

[0047]FIG. 15A is a diagram showing an example of processing by therearrangement part 160;

[0048]FIG. 15B is a diagram showing an example of processing of a 2'scomplement value by the rearrangement part 10;

[0049]FIG. 16 is a flowchart showing another example of the procedure bythe missing information compensating part 430 in the case of usingauxiliary information;

[0050]FIG. 17 is a block diagram corresponding to FIG. 16, illustratingan example of the functional configuration of the missing informationcompensating part 430;

[0051]FIG. 18 is a flowchart showing another example of the procedure bythe missing information compensating part 430 in the case of usingauxiliary information;

[0052]FIG. 19 is a block diagram illustrating a coder and a decoderaccording to Embodiment 5 of the present invention;

[0053]FIG. 20 is a block diagram illustrating a modified form of thedecoder according to Embodiment 5;

[0054]FIG. 21 is a block diagram illustrating a coder and a decoderaccording to Embodiment 6 of the present invention;

[0055]FIG. 22 is a flowchart showing another example of the procedure bythe missing information compensating part 430 in the case of using noauxiliary information;

[0056]FIG. 23 is a block diagram corresponding to FIG. 22, illustratingthe functional configuration of the missing information compensatingpart 430;

[0057]FIG. 24 is a flowchart showing another example of the procedure bythe missing information compensating part 430 in the case of usingauxiliary information;

[0058]FIG. 25 is a block diagram corresponding to FIG. 24, illustratingan example of the functional configuration of the missing informationcompensating part 430;

[0059]FIG. 26 is a flowchart showing another example of the procedure bythe missing information compensating part 430 in the case of usingauxiliary information;

[0060]FIG. 27 is a block diagram illustrating an example of thefunctional configuration of Embodiment 7 of the present invention;

[0061]FIG. 28A is block diagram depicting a concrete example of amodified parameter generating part 17;

[0062]FIG. 28B is a block diagram depicting another concrete example ofthe modified parameter generating part 17;

[0063]FIG. 29 is a block diagram illustrating an example of thefunctional configuration of Embodiment 8 of the present invention;

[0064]FIG. 30 is a is a block diagram illustrating an example of thefunctional configuration of Embodiment 9 of the present invention;

[0065]FIG. 31 is a block diagram illustrating an example of thefunctional configuration of Embodiment 10 of the present invention;

[0066]FIG. 32 is a block diagram illustrating an example of thefunctional configuration of Embodiment 11 of the present invention;

[0067]FIG. 33 is a block diagram depicting an example of the functionalconfiguration of a reversible coding part 18 in FIG. 32;

[0068]FIG. 34 is a block diagram depicting an example of the functionalconfiguration of a reversible decoding part 21;

[0069]FIG. 35A is a block diagram depicting an other example of thefunctional configuration of a reversible coding part 18;

[0070]FIG. 35B is a block diagram depicting an other example of thefunctional configuration of a reversible decoding part 21;

[0071]FIG. 36 is a block diagram illustrating an example of thefunctional configuration of Embodiment 12 of the present invention;

[0072]FIG. 37 is a block diagram illustrating a modified form ofEmbodiment 12;

[0073]FIG. 38 is a block diagram illustrating an example of thefunctional configuration of Embodiment 13 of the present invention;

[0074]FIG. 39 is a block diagram illustrating an example of thefunctional configuration of Embodiment 14 of the present invention;

[0075]FIG. 40 is a block diagram illustrating an example of thefunctional configuration of Embodiment 15 of the present invention;

[0076]FIG. 41 is a block diagram illustrating an example of thefunctional configuration of Embodiment 16 of the present invention;

[0077]FIG. 42 is a diagram showing an example of an accuracy-guaranteedlocally reconstructed signal 11;

[0078]FIG. 43A is a diagram showing another example of theaccuracy-guaranteed locally reconstructed signal 11;

[0079]FIG. 43B is a diagram showing an example of a code group includingan exception code Ige and a digit number code Ig; and

[0080]FIG. 44 is a block diagram illustrating an example of thefunctional configuration of Embodiment 17 of the present invention.

DETAILED DESCRIPTION OF THE PREFERRED EMBODIMENTS

[0081] Referring to the accompanying drawings, embodiments of thepresent invention will hereinafter be described. The parts correspondingto those previously described in respect of the prior art will beidentified by the same reference numerals as those used therefor.

EMBODIMENT 1

[0082] In FIG. 3 there are depicted in block form the coder 10 and thedecoder 20 according to this embodiment of the present invention. Thisembodiment differs from the FIG. 1 prior art example in the provision ofa header adding part 320, which sends out signals in a packet to reducethe influence of a bit error during transmission on the quality ofreconstructed signal.

[0083] In the coder 10 an input signal sample sequence from an inputterminal 100 is separated by a frame forming part 110 into frames eachconsisting of, for example, 1024 input signal samples (that is,n=samples at 1024 sample points), and in the rearrangement part 160 bitsat each bit position in amplitude bit sequences of the respectivesamples are formed in the frame. In this case, the amplitude of theinput signal sample sequence is represented by a positive or negativeinteger in the 2's complement format; it is preferable that, as is thecase with the prior art, each sample represented in the 2's complementformat be converted to an m-bit binary format consisting of a sign bitand absolute value in a sign-magnitude conversion part 161 and thatm-bit samples of each frame be converted to bit sequences each formed bysequential bits at each bit positions of the respective m-bit samplesover the entire frame in a bit sequence converting part 162, which bitsequences will hereinafter be referred to equi-position bit sequences.As indicated by the broken line in FIG. 3, however, the output from theframe separation part 100 may be fed directly to the bit sequenceconversion part 162, wherein bits at each of the bit positions areconcatenated in the frame to form equi-position bit sequences.

[0084] In the present invention, the equi-position bit sequences fromthe rearrangement part 160 are provided to a transmission/recording unitseparation part 310, wherein they are each separated to transmission orstorage unit data. This unit will hereinafter be referred to as a blockand also as a packet. Each piece of the transmission/recording unit dataseparated is reversibly compressed in a reversible coding part 150, ifnecessary. In the header adding part 320 a header containing a serialnumber, for instance, is imparted to each piece of the reversiblycompressed transmission/recording unit so that during decoding theseparated pieces of transmission recording data may be reconstructed asone frame, and the unit data is provided as a packet to an outputterminal 170. Incidentally, the reversible coding part 150 is similar tothat 150 used in the prior art example.

[0085] An ordinary input signal sample represents a positive or negativeinteger in the 2's complement format, but in this example, bits ofnumerical value sequences of every frame after conversion of the digitalinput signal to the binary format consisting of the sign bit andabsolute value are rearranged, that is, converted to the equi-positionbit sequences and they are separated into transmission/recording unitdata as shown in FIG. 4A. The respective m-bit samples of one frame in asign-magnitude format are sequentially arranged in a temporal order asdepicted at the left-hand side of FIG. 4A. For the sake of betterunderstanding of the amplitude bit sequence of an n-th sample, it isshown as a thick-lined amplitude bit sequence DV(n), where n representsthe sample number in a temporal order in the frame; for example, n−1, 2,. . . , 1024. As will be described, for example, in case where inputdata is a speech signal, if a bit is lost due to a packet erasure on thetransmission line, the reconstructed speech quality is distorted moreseriously the higher-order the bit is in the amplitude bit sequenceDV(n). In this instance, the sign bit distorts the speech quality mostseriously; hence, in this example, the sign bit of each amplitude bitsequence DV(n) is placed adjacent to the MSB of the absolute value, andin FIG. 4A it is placed right above MSB.

[0086] In this example, as shown on the right-hand side of FIG. 4A, onlysign bits (signs) of amplitude values of the respective samples arefirst concatenated in a temporal order to form equi-position bitsequences in the frame. Next, only MSBs of the amplitude values areconcatenated in the frame to form an equi-position bit sequence.Thereafter, bits at each of other bit positions are similarlyconcatenated across the frame to form equi-position bit sequences.Finally, only LSBs are concatenated in the frame to form anequi-position bit sequence. An example of such equi-position bitsequences is indicated by a thick-lined frame DH(i), where i representseach bit position in the equi-position bit sequence DV(n); for example,i=1, 2, . . . , 17, counted from the MSB. In the above rearrangement,the contents included in the frame remain unchanged.

[0087] In the transmission/recording unit separation part 310 eachequi-position bit sequence DH(i) or adjacent plural equi-position bitsequences DH(i) are separated into pieces of transmission/recording unitdata. In this case, transmission/recording unit data formed by oneequi-position bit sequence and transmission/recording unit data byplural equi-position bit sequences may be interleaved in one frame.

[0088] Each piece of the transmission/recording unit data is provided tothe header adding part 320, wherein a header 32 is added to thetransmission/recording unit data (payload) 32 as shown in FIG. 4B, forinstance. The header 31 contains a packet number 33 consisting of, forexample, a frame number and the number of the transmission/recordingunit data in the frame, and if necessary, the priority level 34 of thepacket and the data length 35, enabling the decoder side to reconstructthe digital signal sequence for each frame accordingly.

[0089] Transmission of data length 35 is not necessary if the datalength of the transmission/recording unit data is fixed. When it iscompressed in the reversible coding part 150, the data length may,however, sometimes differ with packets.

[0090] In general, an error detecting code 35 for detecting an error inthe packet, such as a CRC code, is added to the end of the payload 32 toform one packet 30, which is provided to the output terminal 170.

[0091] In the case of assigning priorities to the packets 30, codesrepresenting higher priorities are given to packets containingtransmission/recording unit data corresponding to higher-order bitpositions of the amplitude bit sequence. That is, when eachequi-position bit sequence DH(i) is separated, the packet containingdata of smaller i in DH(i) is given a higher priority. In the example ofFIG. 4A, the sign amplitude bit sequence DH(1) containing the sign bitcorresponding to i=1 is given the highest priority. The amplitude bitsequences for the LSB to MSB can be assigned priorities in an increasingorder, instead it is also possible to assign different priority levelsto, for example, plural high-order bits and a common lower levelpriority to plural low-order bits. The number of priority levelsassigned to the bit sequences can be smaller than the number of the bitsequences. In the case of using the reversible compression coding incombination with the high-compression irreversible quantization asdescribed previously with reference to the prior art, the highestpriority level may be given to the bit sequence representing thehigh-compression encoded code as will be described.

[0092] In the decoder 20, when the packet 30 input via an input terminal200 has its transmission/recording unit data reversibly compressed, thepacket 30 is reversibly decoded in a reversible decoding part 210(identical with the conventional decoding part 210), and in atransmission/recording unit assembling part 410, based on the packetnumbers, pieces of transmission/recording unit data of respectivepackets 30 are assembled every frame, for example, as indicated by theequi-position bit sequence DH(i) on the right side of FIG. 4A. Theassembled equi-position bit sequence is fed to a data rearrangement part220, wherein they are converted to an amplitude bit sequence DV(n), thatis, a sample sequence (waveform sample sequence). In this case, wheneach sample is represented by the amplitude value in a sign-absolutevalue format, the equi-position bit sequences are rearranged toamplitude bit sequences in a bit sequence conversion part 221, afterwhich each amplitude bit sequence is converted to a 2's complementbinary format in a 2's complement conversion part 222. Incidentally,when the transmission/recording unit data is based on a equi-positionbit sequence directly rearranged from an amplitude bit sequence in the2's complement format, the amplitude bit sequence from the bit sequenceconversion part 221 is provided as a decoded sample to a frame combiningpart 250 as indicated by the broken lines in FIG. 3.

[0093] In the present invention, if the occurrence of an erasure in aseries of packet numbers of the input packets is detected in an erasuredetecting part 420, which decides that the packets of the packet numbersare missing, and the amplitude bit sequences from the rearrangement part220 are not provided directly to the frame combining part 250, insteadthey are fed to the missing information compensating part 430, whereinthey are compensated for missing information, after which the amplitudebit sequences are provided to the frame combining part 250.

[0094] The compensation for missing information in the missinginformation compensating part 430 is made by estimating the missinginformation from known information. When a packet that usually containsa bit near the LSB side and hence lower in priority fails to transmit,since the value of the bits corresponding to the missing portion cannotbe determined, the waveform has to be reconstructed using a smallnumerical value, for example, 0 or an intermediate value that themissing portion can take. Although the accuracy of a determined numberof bits on the MSB side can be retained, but the bit erasure results inlarge perceptual distortion for the reasons given below. The spectrum ofthe original sound leans in energy toward the low frequency range asindicated by the solid line in FIG. 5, whereas the distortion componentby the bit erasure has a nearly flat spectral shape as indicated by thebroken line and its high-frequency component is larger than in theoriginal sound and heard as noise. To solve this problem, the value ofuncertain waveform is corrected so that the spectrum of the uncertaincomponent becomes close to an average spectrum or a spectrum determinedfor each frame. This reduces the high-frequency component of thespectrum of the distortion component after correction as indicated bythe one-dot chain line in FIG. 5, masking the distortion by the originalsound and hence improving quality.

[0095] That is, when an average spectrum of several preceding frames ora determined spectrum in a separately obtained frame to be described isclose to the solid-lined spectrum in FIG. 5, for instance, compensationis made for the missing information so that a spectrum available frominformation other than the missing information of the current frame goesclose to the solid-line spectrum in FIG. 5. A preferable correctionscheme will be described later on in connection with another embodiment.A simple scheme is to remove a noise component in the high-frequencyrange by smoothing the input reconstructed sample sequence by low-passfilter in the erasure correction part 430. The cut-off characteristicsof the low-pass filter is so chosen as to attenuate the high-frequencycomponent according to the characteristics if the spectral envelope ofthe original signal is known. Alternatively, the cut-off characteristicsmay be adaptively changed according to the shape of an average spectrumobtained as mentioned above or a determined spectrum of each frame.

[0096] Since missing information resulting from a packet erasure can becompensated for in the decoder 20 as described above, even if the codingcompression efficiency is increased by intentionally refraining fromsending the LSB side packets as required, it is possible for the decoder20 to perform decoding or reconstruction with perceptually losslessquality.

EMBODIMENT 2

[0097]FIG. 6 illustrates in block form a second embodiment of thepresent invention. In the coder 10 the input signal sample sequenceseparated for each frame in the frame forming part 110 is provided to anauxiliary information generating part 350. The auxiliary informationgenerating part 350 comprises a spectral envelope calculating part 351,a power calculating part 354 and an auxiliary information coding part352. The input signal sample sequences separated in the frame formingpart 110 for each frame are provided to the spectral envelopecalculating part 351, wherein coefficients representing the spectralenvelope are calculated, for example, as linear prediction coefficientsLPC by linear predictive analysis, and in the power calculating part 354the average power Pa of the input signal sample sequences for each frameis calculated.

[0098] Alternatively, the input signal sample sequences are input to aninverse filter 355 formed based on the linear prediction coefficientsLPC, wherein their spectral envelopes are flattened, and the averagepower of the flattened signals is calculated in a power calculating part356. The linear prediction coefficients LPC and the average power Pa arefed to the auxiliary information coding part 352, wherein they areencoded with low bits such as 30 to 50 bits to provide auxiliaryinformation. The auxiliary information is provided to the header addingpart 320, wherein it is added to a representative packet of each frame,for example, a packet containing the transmission/recording unit dataincluding the sign bit; alternatively, it is output as an independentpacket.

[0099] Incidentally, since an increase in the frame length will notcause an considerable change in the spectral envelope parametercalculated in the spectral envelope calculating part 351 nor will itproduce a significant change in the amount of information of thespectral envelope coefficients encoded in the auxiliary informationcoding part 352, the digital input signal to be applied to therearrangement part 160 is separated by a frame forming part 110′ for aframe length longer than its frame length and then provided to theauxiliary information generating part 350 to enhance the efficiency ofreversible compression as indicated by the broken lines in FIG. 6.

[0100] In the decoder 20, the packet input to the input terminal 200 isfed to a separation part 440, wherein it is separated into thetransmission/recording unit data and the auxiliary information. Thetransmission/recording unit data is provided to the decoding part 210,and the auxiliary information is provided to an auxiliary informationdecoding part 450, which decodes the parameter representing the spectralenvelope of the frame concerned. That is, the linear predictioncoefficients LPC and the average power Pa, are provided to the missinginformation compensating part 430. The missing information compensatingpart 430 uses the spectral envelope coefficients LPC and the a averagepower Pa to compensate for missing information as described previouslyin connection with Embodiment 1.

[0101] Alternatively, each potential combination of values as themissing information (bit) are added to each sample value to obtaincandidates for a compensated sample sequence (waveform), then spectralenvelopes of these candidates are calculated, and that one of thecandidates for the compensated sample sequence (waveform) whose spectralenvelope is the closest to the decoded spectral envelope of theauxiliary information is provided as a compensated sample sequence tothe frame combining part 250. Incidentally, the reversible coding part150 and the decoding part 210 in FIG. 6 may be omitted.

[0102] Compensation Based on Auxiliary Information

[0103] In the case of producing the candidates for the compensatedsample sequence by use of each combination of possible values for themissing information, an increase in the amount of missing information(bit) causes a considerable increase in the number of candidates, givingrise to a problem that is computational complexity. A description willbe given below of the processing by the missing information compensatingpart 430 and its functional configuration that will overcome such aproblem.

[0104]FIG. 7 depicts an example of the procedure to be followed and FIG.8 an example of the functional configuration of the missing informationcompensating part. In the first place, only determined bits input to aprovisional waveform generating part 431 from the rearrangement part 220are used to reconstruct a provisional waveform (a provisional samplesequence) in the frame (S1). The provisional waveform is generated withthe missing bit fixedly set to, for example, 0 or an intermediate valueof the missing bit between the maximum and the minimum. For example, iflow-order four bits are missing, their values are any one of 0 to 15;provisionally, it is set to 8 or 7.

[0105] Next, the spectral envelope coefficients of the provisionalwaveform are calculated in a spectral envelope calculating part 432(S2). The spectral envelope coefficients can be estimated by subjectingthe provisional waveform to an all-pole-type linear predictive codinganalysis used in speech analysis, for instance. On the other hand,received auxiliary information Ax is decoded in the auxiliaryinformation decoding part 450 to provide the spectral envelopecoefficients of the original sound, and in an error calculating part 433the spectral envelope coefficients of the original sound are comparedwith the spectral envelope coefficients of the provisional waveform, andif the error between them is within a given range the provisionalwaveform is provided as a corrected output waveform signal to the framecombining part 250 via a switch SW1 (S3).

[0106] In step S3, if the error between the estimated spectral envelopecoefficients and the decoded spectral envelope coefficients are notwithin a given range, an inverse characteristic of the spectral envelopecoefficients of the estimated provisional waveform are given to theprovisional waveform (S4). More specifically, the spectrum of theprovisional waveform is flattened by applying it via a switch SW2 to,for example, an inverse filter (all-zero) 434 of, for example, a set ofall-pole-type linear prediction coefficients by use of the linearprediction coefficients representing the spectral envelope coefficientsof the provisional waveform calculated in step S2.

[0107] Next, the average power of such spectrum-flattened waveformsignals is calculated in a power calculating part 438, and in anamount-of-correction calculating part 439 the average power and thedecoded average power from in the auxiliary information decoding part450 are used to calculate the amount of correction, for example, theratio or difference between them, and the amount of correction is usedto correct the amplitude of the flattened signal in a power correctingpart 501. That is, the output from the inverse filter 434 is multipliedby or added with the amount of correction to make its power equal to thedecoded power (S5). Next, the amplitude-corrected flattened signal ismultiplied by the spectral envelope coefficients of the auxiliaryinformation to generate a provisional waveform having its spectralenvelope coefficients corrected (S6). That is, the output from the powercorrecting part 501 is applied to an all-pole-type synthesis filter 435using the parameter LPC representing the spectral envelope of theauxiliary information to produce a spectrum-corrected waveform. Thespectral envelope of this waveform is close to that of the originalsound.

[0108] However, the amplitude value of the spectrum-corrected waveformis corrected to a correct value in a correcting part 436 since there isa possibility that the amplitude value contains a bit contradictory tothe determined bit in the amplitude value of the waveform with biterasure (S7). For example, when lower-order four bits of a 16-bitamplitude value are unclear or missing, since an uncertainty width ofvalues that each sample can take is 16, the amplitude value is correctedto that one of the values which is the closest to the spectrum-correctedwaveform. That is, when the amplitude value falls outside the range,(XXXXXXXXXXXX0000˜XXXXXXXXXXXX1111), of values possible for thecorrected sample value in each sample, the amplitude value is correctedto a limit value closest to the sample of the spectrum-correctedwaveform within the possible range. As a result, determined bits of theamplitude value are all coincident with the those of the original sound,and the spectral envelope also becomes equal to that of the originalsound.

[0109] The corrected waveform can be returned, as the provisionalwaveform in step S1, via a switch SW3 to the provisional waveformgenerating part 431 to repeat step S2 et seq. Incidentally, it ispresumed that the waveform (sample value) is an integer value, but in afilter calculation it is handles as a real number; hence, it isnecessary that the filter output value be put in an integer. In the caseof a synthesis filter, the result of conversion differs depending on thewaveform is converted for each sample or for each frame, but the bothmethods can be used.

[0110] The broken lines in FIGS. 7 and 8 show a modification of theabove procedure. That is, after the provisional waveform is flattened instep S4, the flattened waveform (flattened signal) is applied to thesynthesis filter 435 to obtain a spectral-waveform-correctedreconstructed sample sequence (waveform) (S5′), and thespectral-envelope-corrected waveform is amplitude-corrected in a powercorrecting part 501′ (S6′), after which the procedure goes to step S7.In this instance, the average power of the spectral-envelope-correctedwaveform from the synthesis filter 435 is calculated in a powercalculating part 438′, and in an amount-of-correction calculating part439′ an amount of correction is calculated from the calculated averagepower and the decoded power of the auxiliary information (from the powercalculating part 356 in the coder 10), and in a power correcting part501′ the obtained amount of correction is used to correct the amplitudeof the output from the synthesis filter 435.

[0111] Turning next to FIG. 9, a description will be given of anotherexample of the missing information compensating procedure usingauxiliary information.

[0112] Steps S1 to S3 and S6 are identical with steps S1 to S3 and S7 inFIG. 7. In this example, filter coefficients of a single synthesisfilter part 438 are calculated (S4 in FIG. 9) which is an assembly ofthe inverse filter 434 of an inverse characteristic to the spectralenvelope estimated in step S2 and the synthesis filter 435 using thelinear prediction coefficients LPC representing the spectral envelope inthe auxiliary information. In step S5 the provisional waveform isapplied to the synthesis filter 438 to synthesize a corrected waveform.The corrected spectral envelope waveform is amplitude corrected (S6).This amplitude correction is made by the power calculating part 438′,the amount-of-correction calculating part 439′ and the power correctingpart 501′ indicated by the broken lines in FIG. 8.

[0113] The functional configuration for the FIG. 9 is indicated by thebroken lines in FIG. 8. That is, the filter coefficients of thesynthesis filter 438 are calculated in a composite spectral envelopecalculating part 437 from the estimated spectral envelope parameter fromthe spectral envelope calculating part 432 and the decoded spectralenvelope coefficients from the auxiliary information decoding part 450.The calculated filter coefficients are set in the synthesis filter part438, to which the provisional waveform is provided. The output from thesynthesis filter part 438 is amplitude corrected in the power correctingpart 501′.

[0114] The calculation of the filter coefficients of the synthesisfilter part 438 may be conducted, for example, as described previouslyin connection with FIG. 10. The linear prediction coefficients as thespectral envelope coefficients of the provisional waveform are convertedby the coefficient converting part 437 a to the linear predictioncepstrum coefficients Ca, and the linear prediction coefficientsobtained as the decoded spectral envelope coefficients of the auxiliaryinformation are converted by the coefficient converting part 437 b tothe linear prediction cepstrum coefficients Cb. These coefficients Caand Cb are applied to the subtracting part 437 c to obtain thedifferences Cb−Ca, which is inversely converted by the inverseconversion part 437 d to the linear prediction coefficients, which areused as the filter coefficients of the synthesis filter 438. Theconversion to the linear predictive coefficients can be done using, forexample, the method described in Japanese Patent Application Laid-OpenGazette No. 248996/96 entitle “Method for Determining FilterCoefficients of Digital Filter.”

[0115] The procedure of FIG. 9 necessitates the calculation by thesynthesis spectral envelope calculating part 437 but involves only onefiltering calculation of the provisional waveform. The correctionprocessing in FIGS. 7 and 9 may also be performed in the frequencydomain.

[0116] The spectrum correction based on LPC decode from the auxiliaryinformation in steps S6 (or S5′) and S5 in the loop of each of theflowcharts of FIGS. 7 and 9 is indented to reduce the spectraldistortion between the original sound and the reconstructed signal—thisreduces the amount of correction and hence prevents divergence of thecorrected waveform. This can be done in the examples of FIGS. 7 and 9 bymultiplying both of linear prediction coefficients α_(k) of the inversefilter 434 and linear prediction coefficients β_(k) and β_(k)′ of thesynthesis filters 435 and 438 by a k-th power (γ^(k)) of a constant γequal to or smaller than 1 (k being the order of the parameter). In theexample of FIG. 10 the linear prediction cepstrum coefficients Ca and Cbneed only to be multiplied by a constant equal to or smaller than 1. Inthe repetitive process in FIGS. 7 and 9, too, it is also possible to setthe constant γ to a value close to a at the beginning of the repetitionand gradually reduce the value of the constant γ as convergenceproceeds, thereby decreasing the estimation error.

[0117] Incidentally, the multiplication of the coefficients α_(k), β_(k)and β_(k)′ by γ^(k) and the multiplication of the linear predictivecepstrum coefficients by the constant equal to or smaller than 1 areequivalent to a multiplication by predictive coefficients with the bandof the spectral envelope characteristics enlarged, making the spectralenvelope of the provisional waveform (sample sequence) and the decodedspectral envelope of the auxiliary information dull or less sharp.

[0118] In FIGS. 7 and 9, step S3 can be omitted, in which case steps S1,S2, S4, S5 (S5′), S6 (S6′) and S7 are performed only once or repeated apredetermined number of times to output the corrected waveform (samplesequence). Further, as shown in FIGS. 7 and 9, when the number of timesstep S3 is carried out exceeds a predetermined value, the correctedwaveform obtained finally at that time may be output.

EMBODIMENT 3

[0119]FIG. 11 illustrates in block form a third embodiment of thepresent invention applied to the coding scheme that is a combination ofthe high-compression-ratio irreversible coding described previously withreference to the FIG. 1 prior art example and the reversible compressionof the error signal between the reconstructed signal and the originalsignal. As is the case with the FIG. 1 prior art example, in the coder10 the digital input signal sequence from the input terminal 100 isirreversibly quantized in the high-compression-ratio irreversiblequantization part 120, then the quantized information is inverselyquantized (that is, decoded) in the inverse quantization part 130, thenthe difference between the inversely quantized signal (reconstructedsignal) and the original digital input signal sequence from the inputterminal 100 is calculated in the subtraction part 140, and the errorsignal that is the difference signal is applied to the frame formingpart 110. That is, as described previously, the error signal for eachframe is subjected to the rearrangement of its bit sequences and theseparation to the transmission/recording unit data, and thetransmission/recording unit data is reversibly compressed and is addedwith the header 31 in the header adding part 320 to form a packet.

[0120] The quantized code I(n) from the irreversible quantization part120 is also fed to the header adding part 320, wherein it is added withthe header31 to form a packet. At this time, the highest priority levelis assigned to the bit sequence of this quantized code. Further, asindicated by the broken lines in FIG. 11, for the error signal or samplesequence, a parameter representing the spectral envelope of the originalinput signal sample sequence and its average power are generated asauxiliary information in the auxiliary information generating part 350,and the auxiliary information is sent out as an independent packet orafter being stored in a packet with high priority level.

[0121] In this embodiment, the decoder 20 performs correction aftersynthesizing the original sound, that is, after reconstructing theoriginal sound signal waveform by adding together in the adder 240 theoriginal sound signal waveform reconstructed by inverse quantization andthe error signal waveform. In a separation part 440 the irreversiblyquantized code I(n), the auxiliary information and thetransmission/recording unit data are separated from the packet input tothe input terminal 200. The irreversibly quantized code I(n) isinversely quantized in an inverse quantization part 230. The auxiliaryinformation is decoded in the auxiliary information decoding part 450,and the decoded parameter representing the spectral envelope and theaverage power are provided to the missing information compensating part430. On the other hand, the pieces of transmission/recording unit dataare reversibly decoded, assembled together and rearranged in asequential order as described previously, by which the vertical bitsequence, that is, the error signal samples sequence is reconstructed,and the reconstructed error signal and the inversely quantized signalfrom the inverse quantization part 230 are added together in the addingpart 240. The added signal is applied to the missing informationcompensating part 430 when a packet erasure is detected in erasuredetecting part 420.

[0122] The missing information compensating part 430 may use any of theabove-mentioned compensating schemes. In the case of using the decodedparameter representing the spectral envelope of the auxiliaryinformation, the parameter representing the corresponding spectralenvelope, if available in the inverse quantization part 230, can beused. Alternatively, as indicated by the broken lines in FIG. 11, in thecoder 10 the auxiliary information is generated in the auxiliaryinformation generating part 350 from the output error signal from theframe forming part 110 or from the input signal separated frame-wise bythe frame forming part 110′ and input via the input terminal 100, andthe auxiliary information is added to any one of packets, or output asan independent packet. In the decoder 20, the auxiliary information isseparated in the separation part 440, and the auxiliary information isdecoded in the auxiliary information decoding part 450, from which thedecoded information is fed to the missing information compensating part430.

[0123] As described above, in the case of using the irreversiblyquantized code and the error signal, the error signal prior to thesynthesis of the original sound may be compensated for missinginformation in the decoder 20. That is, for example, as shown in FIG.12, in the case of a packet erasure, the rearranged output from therearrangement part 220 is provided to the missing informationcompensating part 430, wherein it is compensated for missinginformation, and the compensated output is applied to the framecombining part 250. For the compensation in the missing informationcompensating part 430 any one of the afore-mentioned schemes can beused. In the case of using the spectral envelope of the auxiliaryinformation, the output from the auxiliary information decoding part 450is used; alternatively, a parameter representing the correspondingspectral envelope, if available in the inverse quantization part 230,may also be used. The reconstructed error signal from the framecombining part 250 and the inversely quantized signal from the inversequantization part 230 are added together in the addition part 240 toreconstruct the original sound signal.

[0124] Also in the examples of FIGS. 11 and 12, the average power neednot always be used as the auxiliary information.

[0125] As depicted in FIG. 11, in case where the coder 10 separates theerror signal in the frame forming part 110 for each frame, thecompression efficiency in the reversible coding part 150 can be enhancedby setting the separation frame in the frame forming part 110, forexample, approximately 16 times longer than the frame (for example, 1024samples) of quantization processing in the irreversible quantizationpart 120. However, the separation frame length in the frame forming part110 causes a decoding delay.

[0126] In the embodiments of FIGS. 6 and 11, the rearrangement part 160need not always be provided with the sign-absolute value conversion part160. In other words, the bit sequences in a format of the 2's complementcan be rearranged. This may decrease the coding efficiency but iseffective in case where only the amplitude resolution (scalability ofamplitude precision) is more important than the compression ratio.

[0127] In the examples of FIGS. 11 and 12, the output from the inversequantization part 230 as well as the output signal from the terminal 260may be used as the reconstructed signal in response to the request forfidelity of the reconstructed signal.

[0128] In the above-described examples, the coder 10 and the decoder 20can also be implemented by executing a coding program and a decodingprogram on a computer. In such cases, the programs are downloaded to aprogram memory of the computer from a CD-ROM or flexible magnetic diskor via a communication line.

[0129] To demonstrate the effect of the present invention, computersimulations on the third embodiment (coding in FIG. 11 and decoding inFIG. 12) were performed. The number of digits of the sample value of theerror signal (including a sign signal) was set to 16; sixth to tenthbits dropped out; the error signal was compensated for being smoothed bya low-pass filter in the missing information compensating part 430; andpsycho-acoustically corrected SNR (perceptually weighted SNR) of adecoded signal (at the output terminal 260) and the cepstrum distance(distortion of the spectral envelope) between the decoded signal and theoriginal sound signal were calculated. The results of the computersimulations are shown in FIGS. 13A and 13B. For reference purposes, SNRand the cepstrum distance with no compensation for missing informationare also shown. From FIGS. 13A and 13B it can be seen that in case of a6-th bit erasure, the compensation for missing information according tothe present invention performs a significant improvement in comparisonto the prior art with no such erasure compensation.

EMBODIMENT 4

[0130]FIG. 14 illustrates the coder 10 and the decoder 20 according toanother embodiment of the present invention. This embodiment is amodification of the auxiliary information generating part 350 in theFIG. 6 embodiment. As previously described, in the coder 10 the inputsignal sample sequence from the input terminal 100 is separated by theframe separation part 100 into frames each consisting of 1024 samples,for instance. In this embodiment, the number of digits representing themaximum one of absolute values of the input digital signals of therespective frames is detected as an effective digit number Fe in aneffective digit-number detecting part 353 in the auxiliary informationgenerating part 350.

[0131] For each frame separated in the frame forming part 110, the inputsignal sample sequences are rearranged in the rearrangement part 160. Inthis embodiment bits of the respective samples (amplitude bit sequences)within the portion corresponding to the effective digit number Fe arearranged in the temporal direction. In this case, the positive- ornegative-integer amplitude of each input signal sample is in a formatbased on a 2's complement, but it is desirable that each sample in aformat based on a 2's complement be converted to a binary numberconsisting of sign bit and absolute value in the sign-absolute valueconversion part 161 as referred to previously with reference to theprior art example and that the corresponding bits (digits) of therespective samples (amplitude bit sequences) be rearranged in the bitsequence conversion part 162 to bit sequences (equi-position bitsequences) in which the corresponding bits are sequentially concatenatedin a temporal order. As indicated by the broken lines in FIG. 14,however, the respective samples in a format of the 2's complement neednot always be provided to the conversion part 161, but instead they mayalso be provided intact directly to the bit sequence conversion part 162in which the samples of the digital signal are rearranged to bitstreamsover samples with the corresponding bits concatenated in a temporalorder.

[0132] That is, an ordinary input signal sample represents the positiveor negative integer in a format of the 2's complement, but in thisexample the input signal sample is converted to a binary numberconsisting of sign bit and absolute value, which is further converted toa numerical value, and then the input signal sample is converted to anequi-position bit sequence (or a bitstreams), thereafter being separatedinto transmission/recording unit data in the transmission/recording unitdividing part 310. An example is shown in FIG. 15A. Respective samplesin the sign-absolute-value format are sequentially arranged in atemporal order for each frame as indicated by the amplitude bit sequenceon the left-hand side of FIG. 15A. For the sake of better understandingof one amplitude bit sequence, it is shown as a thick-lined amplitudebit sequence DV(n), where n represents time in one frame; for example,n=1, 2, . . . , 1024. In this example, the sign bit of each amplitudebit sequence DV(n) is placed right above MSB of the absolute value.

[0133] In this instance, that one of the digits closest to MSB in eachof the amplitude bit sequences of one frame which is “1” is detected,and the number of digits from LSB to the digit “1” is obtained as theeffective digit number Fe. The bits of the digital signals of one framein the range 361 within the effective digit number Fe and the sign bitsare converted to bit sequences. The bits at the digits in the range 362from the digit higher-order than the effective digit number Fe to MSBare not converted to equi-position bit sequences.

[0134] In the first place, as depicted on the right side of FIG. 15A,only sign bits of the amplitude values of respective samples in thisexample are concatenated in a temporal order to produce a sequence(equi-position bit sequence) in the frame. Next, only those digitswithin the effective digit number Fe which correspond to the largestnumerical value are concatenated in the frame to produce sequences(equi-position bit sequences). Similarly, corresponding bits at each ofthe subsequent digits are concatenated in a temporary order to form anequi-position bit sequence, and finally only LSBs are concatenated intoan equi-position bit sequence. An example of these equi-position bitsequences is indicated by the thick-lined bit sequence DH(i) on theright-hand side of FIG. 15A, where i indicates the order of generationof each equi-position bit sequence. The above rearrangement does notever change the contents of the data in the frame.

[0135] Incidentally, when the digital signal represents the positive ornegative integer in a format of the 2's complement, those digitshigher-order than the digit representing the maximum one of the absolutevalues become all “0s” or all “1s” depending on whether the amplitudebit sequences are of positive or negative value as indicated byamplitude bit sequences of one frame in FIG. 15B and as shown in therange 364 in FIG. 15B. the number of digits in the other range 363 isdetected as the effective digit number Fe. Only the bits in the range364 and the bits (digits) adjacent to the range 364, only sign bits, areconverted to equi-position bit sequences as indicated on the right sideof FIG. 15B.

[0136] In the transmission/recording unit separation part 310, theoutput from the rearrangement part 160 is separated to pieces oftransmission/recording unit data every equi-position bit sequence DH(i)or every plurality of adjacent equi-position bit sequences DH(i). Inthis instance, pieces of transmission/recording unit data each formed byone equi-position bit sequence and pieces of transmission/recording unitdata each formed by plural equi-position bit sequences may beinterleaved in the same frame.

[0137] The pieces of transmission/recording unit data thus separated areeach provided to the header addition part 320, wherein the header 31 isadded to the transmission/recording unit data (payload) 32 as shown inFIG. 4C, for instance.

[0138] In this embodiment, the auxiliary information generating part 350comprises a spectral envelope calculating part 351, an auxiliaryinformation coding part 352, an effective digit number detecting part353 and a power calculating part 354. The effective digit number Fedetected by the effective digit number detecting part 353 in the inputsignal sample sequence from the frame forming part 110 is encoded in theauxiliary information coding part 352, thereafter being output.Alternatively, if each sample has an m-bit configuration, it is evidentthat m-Fe may be sent in encoded form in place of the effective digitnumber Fe. Further, in this example, the input signal sample sequenceseparated in the frame forming part 110 for each frame is provided tothe spectral envelope calculating part 351, wherein linear predictioncoefficients LPC are obtained by linear predictive coding analysis, forinstance, as a parameter representing the spectral envelope, and in thepower calculating part 354 the average power Pa of the frame iscalculated. Alternatively, the sample sequence of the input signal isinput to an inverse filter 355 formed based on the linear predictioncoefficients LPC calculated in the spectral envelope calculating part351, by which the spectral envelope is flattened, and the average powerPa of such flattened signals is calculated in the power calculating part356.

[0139] The linear prediction coefficients LPC and the average power Paare also encoded with low bits, about 30 to 50 bits, into auxiliaryinformation in the auxiliary information coding part 340. The auxiliaryinformation encoded from the effective digit number Fe, the spectralenvelope parameters LPC and the average power Pa are provided to theheader addition part 320, wherein they are added in a representativepacket of each frame, for instance, a packet having stored therein thetransmission/recording unit data including a sign bit, or it is outputas an independent packet. Like the FIG. 6 embodiment, the auxiliaryinformation such as the spectral envelope parameters LPC and the averagepower Pa can be obtained for an input signal frame separated in theframe forming part 110′ using a frame length longer than that in theframe forming part 110 as indicated by the broken line, by which theefficiency of the reversible compression can be enhanced.

[0140] In the decoder 20, the packet 30 input to the input terminal 200is separated by the separation part 440 into the transmission/recordingunit data and the auxiliary information. The transmission/recording unitdata is provided to the decoding part 210 (identical with that 210 inFIG. 1), and the auxiliary information is provided to the auxiliaryinformation decoding part 450. The auxiliary information decoding part450 decodes the effective digit number Fe, the spectral envelopeparameters LPC and the average power Pa of the frame concerned, andprovides the effective digit number Fe to a digit adjusting part 460 andthe spectral envelope parameters LPC and the average power Pa to themissing information compensating part 430. The mission informationcompensating part 430, the auxiliary information decoding part 450 andthe digit adjusting part 480 constitute an information compensating part480.

[0141] When the transmission/recording unit data is reversiblycompressed, it is reversibly decoded in the decoding part 210, andrespective pieces of transmission/recording unit data are provided to atransmission/recording unit assembling part 410, wherein based on thepacket numbers, they are assembled into one frame formed by pluralpackets, for example, such an equi-position bit sequence as shown on theright side of FIG. 15A. The assembled data is fed to the rearrangementpart 220, wherein the equi-position bit sequences are converted toamplitude bit sequences, that is, to the signal sample sequences(waveform). In this case, when each sample is represented by anamplitude value in a sign-absolute binary format, the equi-position bitsequences are converted by the bit sequence conversion part 221 intoamplitude bit sequences as depicted on the right side of FIG. 15B unlikethe rearrangement described above with reference to FIG. 15A, and thenin the 2's complement conversion part 222 each amplitude bit sequencefrom the bit sequence conversion part 221 is converted to the 2'scomplement format, that is, the amplitude bit sequence of the negativesign bit has its “1” and “0” exchanged.

[0142] Incidentally, when the transmission/recording unit data is basedthe equi-position bit sequence directly rearranged from the amplitudebit sequence in a format of the 2's complement, the amplitude bitsequence from the bit sequence conversion part 221 is provided intact tothe digit adjusting part 400. The digit adjusting part 460 performsdigit adjusting for each amplitude bit sequence according to the decodedeffective digit number Fe. That is, in order that the number of the bits(the number of digits) of the amplitude bit sequence may become equal tothat of the original signal samples, “0” or “1” is added to thehigh-order digit of the amplitude bit sequence, depending on whether thesign bit is positive or negative, that is, a bit in the range 363 inFIG. 15B, for instance, is added. The digit-adjusted amplitude bitsequence is provided as a decoded sample to the frame combining part250.

[0143] When a packet erasure occurs, the packet number of the missingpacket is detected by the erasure detecting part 420, and the amplitudebit sequence from the rearrangement part 220 is not directly provided tothe digit adjusting part 460, but instead it is fed to the missinginformation compensating part 430, wherein the amplitude bit sequence(sample) is compensated for the missing information, and the amplitudebit sequence is supplied to the digit adjusting part 460.

[0144] The compensation in the missing information compensating part 430is performed by estimating the missing information from knowninformation. The missing information compensating part 430 compensatesfor the missing information so that the spectrum available from otherinformation than the missing information of the frame concernedapproaches an average spectrum of several preceding frames as in theembodiments described previously or a determined spectrum in a frameobtained as the result of decoding of the auxiliary information asreferred to later on. A simple compensating method is to remove a noisecomponent in the high-frequency region by the input reconstructed samplesequence to a low-pass filter in the missing information compensatingpart 430. The cut-off characteristic of the low-pass filter is chosensuch that it attenuates the high-frequency component according to itscharacteristic if the spectral envelope of the original signal is known.Alternatively, the cut-off characteristic may adaptively be changedaccording to the average power or the shape of a spectrum determined foreach frame.

[0145] Even if the bit rate is decreased by intentionally refrainingfrom sending LSB side packets to the decoder 20, as required, with aview to reduction of the amount of information through utilization ofthe fact that the decoder 20 is capable of compensating for theinformation lost because of a packet erasure as described above, thedecoder 20 is capable of implementing decoding or signal reconstructionfree from the psycho-acoustical problem.

[0146] It is also possible to use as an alternative to the above themethod described below. All possible combinations of the missinginformation (bit) are added to each sample value to produce candidatesfor a compensated sample sequence (waveform), then the spectralenvelopes of the candidates are calculated, and that one of thecandidate for the compensated sample sequence (waveform) whose spectralenvelope is the closest to the decoded spectral envelope of theauxiliary information is output as a compensated sample sequence to thedigit adjusting part 460. Incidentally, the reversible coding part 150and the decoding part 210 in FIG. 14 may be omitted.

[0147] Compensation Based on Auxiliary Information

[0148] In the case of producing the candidates for the compensatedsample sequence by use of all possible combinations for the missinginformation, an increase in the amount of missing information (bit)causes a considerable increase in the number of candidates, giving riseto a problem such as an impractical computational complexity. Anembodiment to implement the processing by means of the missinginformation compensating part 430 and its functional configuration isdescribed below.

[0149]FIG. 16 depicts an example of the procedure to be followed andFIG. 17 an example of the functional configuration of the missinginformation compensating part 430. Steps S1 to S6 are the same as stepsS1 to S4, S6 and S7 in FIG. 7. In the first place, only determined bitsinput to the provisional waveform generating part 431 from therearrangement part 220 are used to reconstruct a provisional waveform (aprovisional sample sequence) in the frame (S1). The provisional waveformis reconstructed with the missing bit fixedly set to, for example, 0 oran intermediate value for a possible missing bit. For example, iflow-order four bits are missing, their values are any one of 0 to 15;provisionally, it is set to 8 or 7.

[0150] Next, the spectral envelope of the provisional waveform iscalculated in the spectral envelope calculating part 432 (S2). Thespectral envelope coefficients can be analyzed by subjecting theprovisional waveform to an all-pole-type linear predictive codinganalysis that is used in speech analysis, for instance. On the otherhand, received auxiliary information Ax is decoded in the auxiliaryinformation decoding part 450 to provide the spectral envelopecoefficients of the original sound, and in an error calculating part 433the spectral envelope coefficients of the original sound are comparedwith the spectral envelope coefficients of the provisional waveform, andif the error between them is smaller than a predetermined value Δd, theprovisional waveform is provided as a corrected output waveform signalto the frame combining part 250 (S3).

[0151] In step S3, if the error between the estimated spectral envelopecoefficients and the decoded spectral envelope coefficients is notsmaller than the predetermined value Δd, an inverse characteristic ofthe spectral envelope coefficients of the estimated provisional waveformis given to the provisional waveform (S4). More specifically,coefficients representing the spectral envelope of the provisionalwaveform obtained in step S2 are set in, for example, an all-pole-type(all-zero-type) linear prediction inverse filter 434, and theprovisional waveform is applied to the inverse filter 434 to flatten thespectrum of the provisional waveform to obtain a flattened signal. Theaverage power of such a flattened signal is calculated in the powercalculating part 438. In an amount-of-correction calculating part 439 anamount of correction is calculated from the average power and thedecoded average power (the output from the power calculating part 438)from the auxiliary information decoding part 450 to detect the ratio ordifference between them. Based on the calculated amount of correction,the power correcting part 501 corrects the amplitude of the output fromthe inverse filter 434 that is, multiples or adds the output from theinverse filter 434 by or with the amount of correction so that the powerof the provisional waveform equals to the decoded power (S5).

[0152] Next, the characteristics of the spectral envelope of theauxiliary information is imparted to the amplitude-corrected flattenedsignal to correct its spectral envelope (S6). The output from the powercorrecting part 501 is applied to an all-pole-type synthesis filter 435using the parameters LPC representing the spectral envelope of theauxiliary information to produce a spectrum-corrected waveform. Thespectral envelope of this waveform is close to that of the originalsound.

[0153] However, since there is a possibility that the spectrum-correctwaveform is contradictory to already determined bits in the amplitudebit sequence, it is corrected to a correct value in the correcting part436 (S7).

[0154] Step S2 and the subsequent steps can be repeated using thecorrected waveform as the provisional waveform in step S1. When thedecoded effect digit number Fe differs with frames, the samples can beprocessed by the linear prediction coding analysis in the spectralenvelope calculating part 432 (step S2), by the inverse filter 434 (stepS4) and by the synthesis filter 435 (step S6) span the current andpreceding frames. In this instance, even during the current frameprocessing, it is necessary that the effective digit number Fe of theimmediately preceding frame be made equal to the effective digit numberFe of the current frame prior to the analysis or filtering. When theeffective digit number Fe of the immediately preceding frame is smallerthan the effective digit number Fe of the current frame by N digits, thesample of the immediately preceding frame is shifted N digits to thelow-order side to reduce the amplitude value, with the effective digitnumber equal to that of the current frame. Conversely, when theeffective digit number of the immediately preceding frame is larger thanthe effective digit number of the current frame by M digits, the sampleof the immediately preceding frame is temporarily upward shifted by Mdigits. For example, in the floating-point representation to increasethe amplitude value, with the effective digit number equal to that ofthe current frame. When the amount of information lost by a registeroverflow due to the high-order shift is large, the accuracy of theamplitude value of the sample of the immediately preceding frame isimpaired, so that the sample with the degradation is not used or thesample of the current frame need not always be corrected.

[0155] As indicated by the broken lines in FIG. 16, when such acorrection of the effective digit number is necessary for the analysisin step S2, the above-described correction of the effective digit numberis made (S2′) prior to step S2. When it is necessary for the inversefiltering in step S4, the effective digit number is corrected (S4′)prior to step S4. In case of the synthesis filtering in step S6, theeffective digit number is corrected (S6′) prior to step S6. In FIG. 17,when the spectral envelope calculating part 432, the inverse filter 434and the synthesis filter 435 require the sample of the preceding frame,the reconstructed effective digit number Fe is also provided to any ofthem from the auxiliary information decoding part 450 as indicated bythe broken lines so that they perform their processing after making theeffective digit number of the sample of the preceding frame equal to theeffective digit number of the current frame.

[0156] The broken lines in FIGS. 16 and 17 show a modification of theabove procedure. After the provisional waveform is flattened in step S4,the flattened waveform (flattened signal) is applied to the synthesisfilter 435 to obtain a spectral-envelope-corrected reconstructed samplesequence (waveform) (S5′), and the spectral-envelope-corrected waveformis amplitude-corrected in the power correcting part 501′ (S6′), afterwhich the procedure goes to step S7. In this instance, the average powerof the spectral-envelope-corrected waveform from the synthesis filter435 is calculated in the power calculating part 438′, and in theamount-of-correction calculating part 439′ an amount of correction iscalculated from the calculated average power and the decoded power ofthe auxiliary information (from the auxiliary information decoding part450), and in the power correcting part 501′ the amount of correctionobtained is used to correct the amplitude of the output from thesynthesis filter 435. When the processing by the synthesis filter 435 instep S5′ spans the immediately preceding and the current frame, theeffective digit number is corrected in advance as indicated by step S5″.

[0157] Turning next to FIG. 18, a description will be given of anotherexample of the missing information compensating procedure usingcompensating information. This missing information compensatingprocessing is based on the same principles as those using the compositespectral envelope calculating part 437 and the synthesis filter part435′ in FIG. 8.

[0158] Steps S1 to S3 and S6 are identical with those S1 to S3 and S7 inFIG. 16. In this example, the filter coefficients of the synthesisfilter part 438, which is an assembly of the inverse filters 434 usingthe spectral envelope parameter estimated in step S2 and the synthesisfilter 435 using the spectral envelope parameter of the auxiliaryinformation, are calculated in step S4 in FIG. 16. In step S5 theprovisional waveform is applied to the synthesis filter 438 tosynthesize a waveform of a corrected spectral envelope. The waveform ofthe corrected spectral envelope is amplitude corrected in thebroken-lined power correcting part 501′ (S6). This amplitude correctionis made by the power calculating part 438′, the amount-of-correctioncalculating part 439′ and the power correcting part 501′. The filtercoefficients of the synthesis filter 501′ are calculated, for example,by the scheme described previously with reference to FIG. 10.

[0159] The procedure shown in FIG. 18 necessitates the calculation ofthe filter coefficients of the synthesis filter part 435′ by thecomposite spectral envelope calculating part 437 but involves only onefilter operation for the provisional waveform. The correction processingdepicted in FIGS. 16 and 18 may also be carried out in the frequencydomain.

[0160] When a previous sample is needed for the spectral envelopecalculation in step S2 or for the spectral envelope correction in stepS5 in FIG. 18, the afore-mentioned effective digit number correction ismade prior to step S2 or S5 as indicated by the broken lines (S2′ orS5′).

[0161] In the loop in each of the flowcharts of FIGS. 16 and 18, thespectral envelope correction based on LPC decoded from the auxiliaryinformation in step S6 (or S5′) and S5 is intended to reduce spectrumdistortion, and the correction in step S7 is to reduce waveformdistortion of the reconstructed signal relative to the original sound.The repetition of this operation by the loop does not guaranteeconvergence of the waveform, but as described previously with respect toFIGS. 7B and 9, it prevents divergence of the reconstructed waveformthrough multiplication of linear prediction coefficients α_(k) of theinverse filter 434 and linear prediction coefficients β_(k) and β_(k)′of the synthesis filters 435 and 438 by the constant γ^(k), where γ is0<γ<1 and k is the order of the parameter.

[0162] In the example of FIG. 10 all of the linear prediction cepstrumcoefficients Ca and Cb need only to be multiplied by a constant equal toor smaller than 1. In the repeating process in FIGS. 16 and 18, too, itis also possible to set the constant γ to a value close to 1 at thebeginning of the repetition and gradually reduce the value of theconstant γ as convergence proceeds, thereby decreasing the estimationerror.

[0163] In FIGS. 16 and 18, step S3 may be omitted, in which case stepsS1, S2, S4, S5 (S5′), S6 (S6′) and S7 are performed only once orrepeated a predetermined number of times to output the correctedwaveform (sample sequence). Further, as shown, when the number of timesstep S3 is carried out exceeds a predetermined value, the correctedwaveform obtained finally at that time may be output from the missinginformation compensating part 430.

[0164] The digit adjusting part 460 may be placed immediately behind therearrangement part 220 as indicated by the broken line in FIG. 14. Inthis case, the afore-mentioned adjustment of the effective digit numberin the missing information compensating pat 430 is unnecessary.Moreover, in the missing information compensation shown in FIGS. 16 and18, the amplitude correction in steps S5, S6′ and S6 may be omitted. Inthis instance, the associated parts 438′, 439′ and 501′ are left out. Insome cases, the missing information compensation using the decodedspectral envelope may be omitted and replaced with a differentcompensating scheme such as the afore-mentioned one that uses a low-passfilter, or makes correction to put the spectral envelope coefficients ofthe current frame into agreement with that of the preceding frame. Insuch case, the generation of the auxiliary information about thespectral envelope or the average power is omitted, and the configurationof the missing information compensating part 430 in the decoder 20 willbe different from the FIG. 17 configuration.

EMBODIMENT 5

[0165]FIG. 19 illustrates in block form a fifth embodiment of thepresent invention in which the coding method, which rearranges theeffective digits of the sample in each frame as described previouslywith reference to FIG. 14, is applied to the coding method that is acombination of the high-compression-ratio coding scheme describedpreviously in respect of FIG. 1 and the scheme of reversible compressionof the error signal between the reconstructed signal and the originalsignal. The coder 10 of this embodiment is identical in configurationwith the coder 10 of the FIG. 11 embodiment except that the bit sequenceconversion part 162 performs the rearrangement of the effective digitsdescribed in connection with FIG. 15A or 15B and that the auxiliaryinformation generating part 350 is identical in construction with theauxiliary information generating part 350 in the FIG. 14 embodiment. Thedecoder 20 is also identical in configuration with the decoder 20 in theFIG. 11 embodiment except that the digit adjusting part 460 is providedat the output side of the rearrangement part 220 and the missinginformation compensating part 430 is that in the FIG. 14 embodiment andconsequently in the FIG. 17 embodiment. Accordingly, no detaileddescription will be repeated.

[0166] As described above, in case of using the irreversibly quantizedcode and the error signal, the error signal prior to the synthesis ofthe original sound may be compensated for missing information in thedecoder 20. That is, for example, as shown in FIG. 20, in the case of apacket erasure, the rearranged output from the rearrangement part 220 isprovided to the missing information compensating part 430, wherein it iscompensated for missing information, and the compensated output isapplied to the digit adjusting part 460. When missing information isabsent, the output from the rearrangement part 220 is provided directlyto the digit adjusting part 460, and the digit-adjusted sample sequenceis supplied to the frame combining part 250. For the compensation in themissing information compensating part 430 any one of the afore-mentionedschemes can be used. In the case of using the decoded spectral envelopeof the auxiliary information or/and the decoded average power, thedecoded output from the auxiliary information decoding part 450 is used;alternatively, the parameter LPC representing the corresponding spectralenvelope, if available in the inverse quantization part 230, may also beused. The reconstructed error signal from the frame combining part 250and the inversely quantized signal from the inverse quantization part230 are added together in the addition part 240. As indicated by thebroken lines in FIG. 20, the digit adjusting part 460 may be placedimmediately after the rearrangement part 220.

[0167] The coder 10 sends out at least the effective digit number andthe transmission/recording unit data for each frame and that the decoder20 uses them to perform decoding.

EMBODIMENT 6

[0168]FIG. 21 illustrates in block form a coder 10 and a decoder 20according to a sixth embodiment of the present invention. Thisembodiment sends out a prediction error of the input signal samplesequence after converting it to the equi-position bit sequence insteadof converting the frame-separated input signal sample sequence to theequi-position bit sequence in the FIG. 6 embodiment.

[0169] The coder 10 differs from that 10 in FIG. 6 in the additionalprovision of a prediction error generating part 370 comprised of asample register 371, an integer part 373 and a difference circuit 374.The decoder 20 also differs from that 20 in FIG. 6 in the additionalprovision of a synthesis filter 470 comprised of a sample register 471,a linear prediction part 472, an integer part 473 and an addition part474. The input signal sample sequence is provided for each frame fromthe frame forming part 110 to the spectral envelope calculating part 351of the auxiliary information generating part 350 and the differencecircuit 374 of the prediction error generating part 370. The inputsignal sample sequence is subjected for each frame to, for example,linear predictive coding in the spectral envelope calculating part 351,from which is provided linear prediction coefficient LPCs as parametersrepresenting the spectral envelope. The spectral envelope parameters LPCare encoded in the auxiliary information coding part 352.

[0170] For example, a predetermined number of samples of the immediatelypreceding frame from the frame forming part 110 is supplied from theregister 371 to the linear prediction part 372, wherein these samplesequences are multiplied by or added with linear prediction coefficientsbased on the spectral envelope parameters LPC from the spectral envelopecalculating part 351, by which is calculated linear prediction for eachinput sample. The linear prediction value is converted in the integerpart 373 to an integer value. The difference between the predictionvalue in an integer form and the current sample from the frame formingpart 110 is calculated as a prediction error signal sample Spe in thedifference circuit 374.

[0171] The obtained prediction error signal Spe for each input sample isapplied to the rearrangement part 160, wherein corresponding bits(digits) of the prediction error signal samples Spe (amplitude bitsequences) for the respective input samples are arranged in a temporalorder for each frame as described previously with reference to FIG. 4A.The equi-position bit sequences from the rearrangement part 160 areseparated by the transmission/recording unit separation part 310 totransmission unit or recording unit data. These separated pieces oftransmission/recording unit data are subjected to reversible compressioncoding, if necessary, in the reversible coding part 150, and in theheader adding part 320 the separated pieces of transmission/recordingunit data are added with the header so that they can be reconstructed asone frame when decoded, thereafter being provided as a packet to theoutput terminal 170.

[0172] The coding information (auxiliary information) for the spectralenvelope parameters LPC from the auxiliary information coding part 350is output as one packet from the header adding part 320 or outputtherefrom after being loaded in the packet of the highest prioritylevel.

[0173] In the decoder 20, the packets from the input terminal 200 areeach separated to the auxiliary information and thetransmission/recording unit data (containing a sign bit sequence) in theseparation part 440, the auxiliary information is provided to theauxiliary information decoding part 450. When reversibly compressed, thetransmission/recording unit data is fed to the decoding part 210,wherein it is reversibly decoded, and each piece oftransmission/recording unit data is provided to thetransmission/recording unit assembling part 410, wherein based on thepacket numbers, pieces of transmission/recording unit data of one frameare assembled from plural packets. The assembled data is provided to therearrangement part 220, wherein bit sequences are converted signalsamplesof one frame, providing a prediction error waveform.

[0174] Incidentally, when the transmission/recording unit data is basedon the equi-position bit sequence directly rearranged from the amplitudebit sequence in a format of the 2's complement, the amplitude bitsequence from the bit sequence conversion part 221 is provided intact asa decoded sample to the synthesis filter 470, bypassing the missinginformation compensating part 430 as indicated by the broken lines inFIG. 21. When no packet are erased occurs, exactly the same predictionerror signal Spe as the prediction error signal samples Spe input to therearrangement part 160 of the coder 10 is provided from therearrangement part 220. The synthesis filter 470 performs processinginverse to the synthesis filter prediction error generating part 370 ofthe coder 10. That is, a predetermined number of immediately precedingsamples are input from the register 471 to the linear prediction part472, wherein the samples are each multiplied by the linear predictioncoefficients LPC decoded in the auxiliary information decoding part 450,and the sum of the results of multiplication is provided as a predictionvalue of the current sample. This prediction value is rendered by theinteger part 463 to an integer value, and the sum of this integer valueand the current prediction error signal from the rearrangement part 220is calculated in the addition part 474, and the sum if provided as thefilter output from the synthesis filter 470 to the frame combining part259 and the register 471 as well. Accordingly, digital signals aresynthesized in the synthesis filter 470 and concatenated in the framecombining part 250, and the signal input to the input terminal 100 ofthe coder 10 is reconstructed and provided to the output terminal 260.

[0175] When a packet is erased occurs, the packet number of the inputpacket concerned is detected in the erasure detecting part 420, and theamplitude bit sequence from the rearrangement part 220 is not provideddirectly to the synthesis filter 470. Instead they are supplied to themissing information compensating part 430, wherein the amplitude bitsequence (the prediction error signal) is compensated for the missinginformation, and the compensated output is applied to the synthesisfilter 470.

[0176] Compensation for Missing Information

[0177] A description will be given, with reference to FIGS. 22 and 23,of the procedure and configuration of the missing informationcompensating part 430 for obtaining the prediction error waveformcompensated for missing information.

[0178] A prediction error waveform (the one-frame sample sequence outputfrom the rearrangement part 220) is input to a provisional waveformgenerating part 431, which generates a provisional prediction errorwaveform in the frame using only determined bits (S1). At this time,missing bits are fixed to, for example, to zeros or an intermediatevalue in the range of all potential values.

[0179] Next, the spectral envelope of the provisional prediction errorwaveform is calculated in a spectral envelope calculating part 432 (S2).The spectral envelope can be estimated by subjecting the provisionalprediction error waveform to, for example, all-pole-type linearpredictive coding analysis that is used in speech analysis. Since thespectral envelope of the prediction error waveform generated in theprediction error waveform generating part 370 of the coder 10 becomessubstantially flat, it is expected that the estimated spectral envelopeis flat if the provisional prediction error waveform is identical withthe waveform of the original prediction error signal obtained in theprediction error generating part 370 of the coder 10. However thespectral envelope does not become flat if the provisional predictionerror waveform differs from the waveform of the original predictionerror signal. It is checked in a flatness decision part 433F if theflatness is within a given limit (S3). If the flatness is within thelimit, the provisional prediction error waveform is output intact to thesynthesis filter 470.

[0180] The decision of the flatness uses, as the criterion therefore, avalue obtained by dividing the arithmetic means of linear predictioncoefficients c₁, C₂, . . . , C_(M) obtained as parameters of thespectral envelope in the spectral envelope calculating part 432 by thegeometric mean of the coefficients. E.g., if the above-mentioned valueis 0 dB, then it is decided that the spectral envelope is completelyflat, and if the value is 3 dB or less, for instance, it is decided thatthe spectral envelope is substantially flat. Alternatively, LPC cepstrumcoefficients are used as the spectral envelope parameters. For exampleif the sum of their squares is smaller than a certain value, it isdecided that the spectral envelope is substantially flat.

[0181] When it is decided that the spectral envelope configurationgreatly differs from the flat configuration, a first step is tointroduce an inverse characteristics of an estimated spectral envelopeto the provisional prediction error waveform (S4). Concretely, theprovisional prediction error waveform is applied to, for example, anall-pole-type linear prediction inverse filter (all-zero) 434 to flattenthe spectrum of the provisional prediction error waveform. The spectralenvelope need not be completely flattened but with the bandwidth of thespectral envelope characteristic enlarged, consequently the steepness ofthe spectral envelope can be reduced.

[0182] Since there is a possibility that the flattened waveform iscontradictory to determined amplitude bits obtained from normallyreceived packets, it is corrected to a correct value in a correctingpart 436 (S5). For example, when lower-order four bits of an amplitudevalue of 16-bit accuracy are missing, values possible for each amplitudebit sequence (prediction error signal) originally represents one of 16uncertain values, but if the corrected spectrum waveform contains anamplitude bit sequence outside the range of the 16 values the waveformis corrected to a value closest to the amplitude within the range, inthis example, 15 that is an amplitude bit sequence represented by thevalue of lowest-order four bits.

[0183] As a result, the determined bits of the amplitude value are allequal and the spectral envelope is reconstructed in a waveform close tothat of the original prediction error signal. If necessary, theprocedure returns to step S1, repeating the correction processing usingthe corrected waveform as the provisional prediction error.

[0184] Incidentally, it is presumed that the corrected prediction error(provisional prediction error) waveform is an integer value, but in afilter calculation it is handled as a real number; hence, it isnecessary that the filter output value be put in an integer form. In thecase of a synthesis filter, the result of conversion differs dependingon the waveform is converted for each amplitude or for each frame, butthe both methods can be used.

[0185] In the case of producing the candidates for the compensatedsample sequence by use of all possible combinations of values for themissing bits, an increase in the number of missing bits causes aconsiderable increase in number of candidates for the compensatedamplitude bit sequence (waveform), giving rise to a problem i.e., animpractical computational complexity. A description will be given belowof the processing by the missing information compensating part 430 andits functional configuration that will solve such a problem.

[0186]FIG. 24 depicts an example of the procedure to be followed andFIG. 17 an example of the functional configuration of the missinginformation compensating part 430. In the first place, only determinedbits input to the provisional waveform generating part 431 from therearrangement part 220 are used to reconstruct a provisional predictionerror waveform (a provisional amplitude bit sequence) in the frame (S1).The provisional prediction error waveform is reconstructed with themissing bits fixed to, for example, 0 or an intermediate value within arange of the possible values for the missing bits. For example, iflowest-order four bits are missing, any one of levels from 0 to 15 canbe correct, provisionally, set to 8 or 7.

[0187] Next, the linear prediction coefficients LPC of the spectralenvelope produced by decoding the received auxiliary information are setin the synthesis filter 435, and the provisional prediction errorwaveform is applied to the synthesis filter 435 to synthesize theoriginal input signal waveform to the coder 10 by linear prediction(S2). The spectral envelope of the synthesized waveform is calculated ina spectral envelope calculating part 432 (S3). In an error calculatingpart 433 the calculated spectral envelope and the spectral envelope ofthe original sound (the original input signal) received as auxiliaryinformation, are compared by calculating the spectral envelope decodedin the auxiliary information decoding part 450. If the error between thetwo spectral envelopes is within a given limit, the provisionalprediction error waveform is output as a compensated prediction errorwaveform (compensated amplitude bit sequence) to the synthesis filter470. (S4).

[0188] If the spectral envelope of the provisional prediction errorwaveform and the spectral envelope generated by decoding the auxiliaryinformation greatly differ from each other in step S4, that is, if theprovisional prediction error is incomplete, an inverse characteristicsof the calculated spectral envelope is introduced to the provisionalprediction error waveform (S5). Concretely, the provisional predictionerror waveform is applied to, for example, an all-pole-type linearprediction inverse filter (all-zero) 434 to flatten the spectrum of theprovisional prediction error waveform. The spectral envelope need not becompletely flattened but with a bandwidth of the spectral envelopecharacteristic broadened, consequently the steepness of the spectralenvelope can be reduced.

[0189] Next, the characteristic of the reconstructed spectral envelopeis imparted to the flattened signal (S6). The output from the inversefilter is applied to an all-pole-type synthesis filter 435 having settherein the parameters LPC representing the spectral envelope generatedby decoding auxiliary information to produce a prediction error waveformbased on the provisional prediction error waveform. The resultingprediction error waveform can approximate the original prediction errorwaveform (signal).

[0190] As is the case with FIG. 22, since there is a possibility thatthe corrected prediction error waveform contains a bit contradictory toa known amplitude bit, the prediction error waveform is corrected to acorrect value in the correcting part 436 (S7).

[0191] Step S2 and the subsequent steps are repeated using the correctedprediction error waveform as the provisional prediction error waveformin step S1. As indicated by the broken lines in FIGS. 24 and 25, step S4may also be followed by step S5′ in which to synthesize the provisionalprediction error waveform by use of the reconstructed spectral envelopeparameter (by applying the provisional waveform to a synthesis filter435′) then by step S6′ in which to introduce the inverse characteristicof the calculated spectral envelope to the synthesized waveform (byapplying the waveform to an inverse filter 434′). In case of omittingcoefficients with the broadened bandwidth, the waveform synthesized forobtaining the prediction coefficients, that is, the output waveform fromthe synthesis filter 502 may be supplied to the inverse filter 434.

[0192] Turning next to FIG. 26, a description will be given of anotherexample of the missing information compensating procedure using thereconstructed spectral envelope.

[0193] Steps S1 to S4 and S7 are identical with those S1 to S4 and S7 inFIG. 24. In this example, after step S6, the filter coefficients of thesynthesis filter part 438, which is an assembly of the inverse filter434 using the spectral envelope coefficients estimated in step S2 andthe synthesis filter 435 using the reconstracted spectral envelopeparameters, are calculated (S5). In step S6 the provisional predictionerror waveform is applied to the synthesis filter 438 to synthesize acorrected prediction error waveform.

[0194] The functional configuration for implementing the process shownin FIG. 26 is indicated by the broken lines in FIG. 25. The filtercharacteristics of the synthesis filter part 438, which is a combinationof the inverse filter 434 and the synthesis filter 438, is calculated inthe synthesis spectral envelope calculating part 437 from the decodedspectral envelope parameters LPCs from the auxiliary informationdecoding part 450 and estimated spectral envelope parameters cc from thespectral envelope calculating part 432. Then the provisional predictionerror waveform is applied to the synthesis filter part 438.

[0195] The calculation of the filter coefficients of the synthesisfilter part 438 is conducted as described previously with reference toFIG. 10. That is, the linear prediction coefficients of the provisionalerror waveform are converted in the coefficient conversion part 437 a tolinear prediction cepstrum coefficients Ca, and the linear predictioncoefficients of the reconstructed spectral envelope are converted in thecoefficient conversion part 437 b to the linear prediction cepstrumcoefficients Cb. These coefficients Ca and Cb are provided to thesubtraction part 437 c to calculate the difference Cb−Ca, which isinversely converted in the inverse conversion part 437 d to the linearprediction coefficients, which are used as the filter coefficients ofthe synthesis filter part 438.

[0196] To prevent divergence of the prediction error waveform by therepetitive processing in the flowchart of FIG. 22, the linear predictioncoefficients α_(k) of the inverse filter 434 in the examples of FIGS.22, 24 and 26 and the linear prediction coefficients β_(k) and β_(k)′ ofthe synthesis filters 435 and 438 in the examples of FIGS. 24 and 26 aremultiplied by the k-th power of the constant γ equal to or smaller than1 (k being the order of the parameter). In the example of FIG. 10 thelinear predictive cepstrum coefficients need only to be multiplied by aconstant equal to or smaller than 1. In the repetitive process in FIGS.22, 24 and 26, too, it is also possible to set the constant γ to a valueclose to a at the beginning of the repetition and gradually reduce thevalue of the constant γ as convergence proceeds, thereby decreasing theestimation error.

[0197] Steps S3 in FIG. 22 and S4 in FIGS. 24 and 26 may be omitted, andsteps S1, S2, S4 and S5 in FIG. 22 and S1, S2, S5, S6 and S7 in FIGS. 24and 26 may be performed only once or repeatedly a predetermined numberof times to output the corrected prediction error waveform (amplitudebit sequences). When the repetition counts of steps S3 in FIG. 22 and S4in FIGS., 24 and 26 exceed a prescribed value, the corrected predictionerror waveform finally available may be output. The processing in FIGS.22, 24 and 26 may also be carried out in the frequency domain. In thiscase, for example, inverse filtering becomes a normalization process.

[0198] The amplitude of the prediction error signal Spe frequentlybecomes smaller. When the prediction error signal Spe is represented bya binary number consisting of a sign and absolute value, high-orderdigits of each prediction error signal Spe (amplitude bit sequence)become “0s” throughout the frame in many case as referred to previouslywith respect to FIGS. 15A and 15B. Accordingly, the number of digitsrepresenting the maximum value of the absolute value in one frame iscalculated as the effective digit number, that is the maximum number ofdigits including “1” is detected as the effective digit number Fe in aneffective digit number detecting part 163 of the coder in FIG. 21. Theeffective digit number Fe is also encoded in the auxiliary informationcoding part 352, from which it is output together with the spectralenvelope parameters LPC, and only bits in an range 41 of the effectivedigit number Fe and the sign bit are converted to an equi-position bitsequence in the rearrangement part 160, from which it is output to thetransmission/recording unit separation part 310.

[0199] In the decoder 20, the reconstructed prediction error waveformformed by the amplitude bit sequences from the rearrangement part 220 orthe corrected amplitude bit sequences is digit-adjusted in the digitadjusting part 460 using the effective digit number Fe reconstructed inthe auxiliary information decoding part 430. For example, when thereconstructed prediction error waveform (amplitude bit sequences) inputto the digit adjusting part 460 is like the amplitude bit sequences ofthe digit number Fe on the right side of FIG. 15B, those of theamplitude bit sequences (in a format of the 2's complement) whose signbits are positive (“0”) as shown on the left side of FIG. 15B are eachadded at high-order places with “0s” equal in number to the differencem-Fe between the bit width m of each amplitude bit sequence (the bitwidth of the prediction error signal Spe input to the rearrangement part160 in the coder 10) and the effective digit number Fe. And theamplitude bit sequences of negative sign bits (“1”) are added athigh-order place with “1s” of the same number as m-Fe.

[0200] The reconstructed prediction error waveform thus digit adjustedis provided to the synthesis filter 470. The addition of the effectivedigit number to the auxiliary information enhance the coding efficiency.Incidentally, the prediction error signal (amplitude bit sequences) neednot always be converted to that in the binary format consisting of thesign bit and the absolute value in the rearrangement part 160 of thecoder 10, instead the effective digit number Fe can be output asauxiliary information for the amplitude bit sequences in a format of the2's complement, too. Also in this instance, the number of digitslowest-order than those highest-order digits which are “0” or “1” incommon to all the amplitude bit sequences, as depicted on the left sideof FIG. 15B are the effective digit number Fe, and the least significantbits of the effective digit number Fe can be used as the sign bit.

[0201] In case of using the effective digit number Fe, when areconstructed prediction error signal of the immediately preceding frameis required for the analysis processing and filtering in the spectralenvelope calculating part 432, the inverse filter 434, the synthesisfilter 435, the synthesis filter 502 and the synthesis filer 435′ in themissing information compensating part 430 of the decoder 20 (FIG. 25),prior to the processing the effective digit numbers Fe of theimmediately preceding frame should equal the current frame. For example,when the effective digit number of the current frame is larger than theeffective digit number of the immediately preceding frame by M bits(digits), the amplitude bits sequences of the immediately precedingframe, for instance, are each download shifted by M bits to reduce theamplitude value of the amplitude bit sequence of the previous frame tomeet the effective number of digits of the immediately preceding framewith the effective number of digits of the current frame. When theeffective digit number of the current frame is smaller than that of theimmediately preceding frame by N bits (digits), the amplitude bitsequence of the immediately preceding frame is temporarily upwardshifted by M digits. For example, in the floating-point representationto increase the amplitude value of the amplitude bit sequence of theimmediately preceding frame, the effective digit number equal to that ofthe current frame. Alternatively, the processing is carried out by usingthe other preceding frame, rather than the immediately preceding frame.

[0202] In case of making the effective digit numbers of the current andimmediately preceding frames equal to each other, the amplitude bitsequence of the immediately preceding frame is subjected to the aboveadjustment in the effective digit number immediately prior to steps S2and S4 in FIG. 22, S2, S3, S5 and S6 in FIG. 24 and S2, S3 and S6 inFIG. 26 as indicated by the broken lines. In the missing informationcompensating part 430 in FIGS. 23 and 25, the amplitude bit sequence ofthe immediately preceding frame needs only to be subjected to aboveadjustment to its effective digit number. As shown in the decoder 20 inFIG. 21, the amplitude bit sequence from the rearrangement part 220 mayalso be digit-adjusted in the digit adjusting part 460, in which casethere is no need for the above-mentioned correction of the effectivedigit number.

EMBODIMENT 7

[0203] It is customary in the prior art that the high-compression-ratiocoding of an acoustic signal is designed to minimize perceptualdistortion in view of the perceptual characteristics. This is a codingscheme that utilizes perceptual optimization, and is intended tominimize a perceptual quantization distortion by use of frequencymasking. To minimize the energy of quantization distortion independentlyof the perception, the quantization distortion is dispersed ordistributed independently of the magnitude of the spectrum of theoriginal sound.

[0204] In a perceptual optimization, since the quantization distortionaround a major spectrum component of the original sound is masked by thecomponent of the original sound and is not perceived, the amount ofdistortion is made near the major spectrum component of the originalsound but small near its small spectrum component.

[0205] For example, in the combination of high-compression-ratioirreversible coding and coding as in the FIG. 11 embodiment, if theperceptual characteristics is considered in the irreversible coding, thewaveform of the locally reconstructed signal (the output from theinverse quantization part 130 in FIG. 11) is seriously distortedparticularly in a relatively large spectrum component. Consequently, theerror signal between the locally reconstructed signal and the originalinput acoustic signal is relatively large in its amplitude variation;hence, even the reversible compression coding by the afore-mentionedrearrangement does not sufficiently increase the coding efficiency. FIG.27 illustrates in block form a seventh embodiment of the presentinvention intended to overcome the above-mentioned problem.

[0206] In the coder 10 an acoustic signal sample sequence input to theinput terminal 100 is separated by the frame forming part 110 intoframes each consisting of, for example, 1024 samples. The acousticsignal of each frame is applied to a perceptual optimization coding part13, wherein it is subjected to irreversible compression coding takingthe perceptual characteristics into account. The perceptual optimizationcoding is compression coding of the acoustic signal so as to minimizeperceptual distortion; for example a coding scheme specified in MPEG canbe used. The perceptual optimization coding part 13 outputs aperceptually optimized code Ina that is an irreversible code.

[0207] The perceptually optimized code Ina is locally reconstructed in alocal decoding part 14 to provide a locally recommended signal. Thelocally reconstructed signal for the code Ina can be obtained in theperceptual optimization coding part 13 due to its analysis-by-synthesiscoding scheme. The locally reconstructed signal is fed to a modificationpart 15, wherein it is modified so that the difference or error betweenit and the output acoustic signal from the frame forming part 110 issmall. That is, the error between the locally reconstructed signalmodified in the modification part 15 (a modified local signal) and theacoustic signal from the frame forming part 110 is calculated in anerror calculating part 16. The locally reconstructed signal is modifiedin the modification part 15 so that the energy of the error signal maypreferably be minimized.

[0208] This modification is carried out by multiplying the locallyreconstructed signal by a modification parameter generated in amodification parameter generating part 17, or by weighted addition ofplural samples to the locally reconstructed signal. The modificationparameter is generated, for example, in the manner described below.

[0209] Set a p-order modification parameter A(1×p), an input acousticsignal X(1×n) consisting of n samples and a locally reconstructed signalmatrix Y(p×n) as follows: $\begin{matrix}\begin{matrix}{A = \left( {a_{0},a_{1},\ldots \quad,a_{({p - 1})}^{T}} \right.} \\{X = \left( {x_{0},x_{1},\ldots \quad,x_{({n - 1})}^{T}} \right.} \\{Y = \begin{pmatrix}y_{0} & y_{1} & \cdots & y_{p - 1} \\y_{1} & y_{2} & \cdots & y_{p} \\\vdots & \vdots & ⋰ & \vdots \\y_{n - 1} & 0 & \cdots & 0\end{pmatrix}}\end{matrix} & (1)\end{matrix}$

[0210] where ( )^(T) represents transposition of the matrix.

[0211] The energy d of the error signal is as follows:

d=(X−YA)^(T)(X−YA)   (2)

[0212] The modified parameter A that minimizes d is as follows:

A=(Y ^(T) Y)⁻¹ Y ^(T) X   (3)

[0213] (Y^(T)Y) is an auto-correlation matrix, Y^(T)X can approximates across correlation energy, and the modified parameter a₀ when p=1 is anormalization of the cross correlation coefficient between X and Y bythe energy of Y.

[0214] Further, the correlation coefficient b between U(=X−Y) and Y iscalculated and the following Z can be used as the error signal.

Z=X−Y−bY   (4)

[0215] That is, Z=X−(1+b)Y≡X−a₀Y.

[0216] In the modified parameter generating part 17, as shown in FIG.28A, the cross correlation vector between the input acoustic signal Xand a transposed matrix of the locally reconstructed signal Y iscalculated in a multiplication part 171, the auto correlation matrixY^(T)Y is calculated in a multiplication part 172 and the result ofcalculation in the multiplication part 171 is divided by the result ofcalculation in the multiplication part 172 in a division part 173 togenerate the modified parameter A. Alternatively, the modified parametera₀ may be obtained by calculating the cross correlation coefficientbetween X and Y in the multiplication part 171 and the energy of Y inthe multiplication part 172, and dividing the cross correlationcoefficient by the energy of Y in the division part 173.

[0217] The modified parameter a₀ may also be obtained, as depicted inFIG. 28B, by calculating X−Y=U in a subtraction part 174 and the crosscorrelation coefficient b between U and Y in a multiplication part 175and adding 1 to b in an addition part 176.

[0218] The modified parameter A, a₀, or b are encoded and output as amodified parameter code Inm from the modified parameter generating part171. Thus, the modified parameter contains the cross correlationcomponent between the acoustic signal X and the locally reconstructedsignal Y, and in the modifying part 15 the locally reconstructed signalY is multiplied by the modified parameter or a weighted addition orconvolution of the locally reconstructed signal by the modifiedparameters A.

[0219] Incidentally, if the energy of the error signal between theacoustic signal and the locally reconstructed signal is minimized, theerror signal has no correlation to the acoustic signal and the locallyreconstructed signal. If the energy of the error signal is notminimized, there is correlation between the error signal and theacoustic signal and the locally reconstructed signal. This correlationcomponent is calculated; the locally reconstructed signal Y is modifiedby Eq. (3) in accordance with the correlation component and the modifiedparameters A of Eq. (2) is determined which minimizes the energy of theerror signal.

[0220] The generation of the modified parameters A may also be performedby setting a proper value at first and sequentially correcting it foreach frame so that the amplitude or energy of the error signal U maydecrease. In this instance, the modified parameter code Inm need not beoutput.

[0221] The error signal from the error calculating part 16 is reversiblyencoded in a reversible coding part 18, from which it is output as areversibly encoded code Pne. The reversible coding can be done by acombination of the bit rearrangement with Huffman coding, arithmeticcoding, or similar entropy coding as described in Japanese PatentApplication Laid-Open Gazette No. 2001-44847 referred to previously withreference to FIGS. 1 and 2.

[0222] Since the locally reconstructed signal is modified in themodifying part 15 so that the error between it and the acoustic signalbecomes small, the number of “0” bits in the error signal is larger thanin the error signal between the unmodified locally reconstructed signaland the acoustic signal; hence, the modification of the locallyreconstructed signal provides increased efficiency in the reversiblecoding of the error signal.

[0223] The perceptually optimized code Ina, the reversibly encoded codeIne and, if necessary, the modified parameter code Inm are combined in acombining part 320. Incidentally, it is also possible to adopt a schemethat, as depicted in FIG. 28B, multiplies the locally reconstructedsignal Y by a modified parameter b in the modifying part 15 to obtain amodified locally reconstructed signal bY, calculates an error U−bYbetween the modified locally reconstructed signal bY and U=X−Y in theerror calculating part 16 to obtain an error signal and reversiblyencodes it. Since this error signal is essentially identical with theerror signal Δ=X−a₀Y, the calculation of the error signal between theacoustic signal and the modified locally reconstructed signal means theboth schemes and a scheme equivalent thereto.

[0224] In the decoder 20, the set of codes for each frame input to theinput terminal 200 is separated by the separation part 440 to theperceptually optimized code Ina, the reversibly encoded code Ine and, ifnecessary, the modified parameter code Inm. The perceptually optimizedcode Ina is irreversibly decoded in an perceptually optimized codedecoding part 23 to generate a decoded signal. The scheme for thisdecoding is identical with the scheme used in the local decoding part 14of the coder 10. The decoded signal is modified in a modifying part 24through multiplication by a constant or plural-sample weighted addition.This modification is also identical with that in the modifying part 15of the coder 10. When the modified parameter code Inm is input thereto,a modification parameter generating part 25 decodes it to generate themodification parameters A or a₀ or b. When the modified parameter codeInm is not input thereto, the modified parameter generating part 25 usesthe decoded signal Y and the reconstructed acoustic signal X tocalculate the modified parameters A by sequential correction using thescheme identical with that used by the modification parameter generatingpart 17 of the coder 10.

[0225] The reversibly encoded code Ine is reversibly decoded in areversible decoding part 21 to reconstruct the error signal Δ. The errorsignal Δ and the modified decoded signal aY are added together in anaddition part 27 to reconstruct the acoustic signal. The reconstructedacoustic signal is applied via a switching part 28 to the framecombining part 250, wherein reconstructed acoustic signals of respectiveframes are sequentially concatenated, thereafter being output therefrom.Upon detection of a correctable or compensable packet erasure by theerasure detecting part 420, such a compensation as described previouslyin respect of FIG. 23, for instance, is carried out by the informationcompensating part 480.

[0226] When the reversibly encoded code Ine is not input, or when theerror signal Δ of satisfactory quality cannot be obtained due to aerasure of some amount of information, it is detected by the erasuredetecting part 420, and the detected output is used to control theswitching part 28, through which the decoded signal from theperceptually optimized code decoding part 23 is applied to the framecombining part 250. For ultimate reversible coding, the smaller theenergy of the quantized error is, the higher the compression efficiencyis; but when information about only the perceptually optimized code Inais available, the use of the quantization result which minimizesperceptual distortion improves the signal quality despite 1 bit rate. Ina decoder without the reversible decoding part 26 and so on, too, theperceptually optimized code Ina can be decoded into a reconstructeddigital signal.

EMBODIMENT 8

[0227]FIG. 29 illustrates in block form an eighth embodiment of thepresent invention, in which the parts corresponding to those in FIG. 27are identified by the same reference numerals. The coder 10 differs fromthe counterpart 10 of the FIG. 27 in the construction of the modifyingpart 15. That is, in this embodiment the error signal between thelocally reconstructed signal Y from the local decoding part 14 and theacoustic signal X is calculated in an error calculating part 15A. Theerror signal is subjected to irreversible compression coding in an errorminimization coding part 15B so that the energy of quantized errorbecomes minimum, and an error minimized code Inp is provided as theirreversibly encoded code.

[0228] The error minimized code Inp is locally decoded in a localdecoding part 15C, and the locally reconstructed signal and that fromthe local decoding part 14 are added in adding part 15D. The errorbetween the added locally reconstructed signal and the acoustic signalis calculated in the error calculating part 16, from which an errorsignal is provided to the reversible coding part 18. Since the acousticsignal is encoded twice in the perceptual optimization coding part 13and the error minimization coding 15B as described above, the locallyreconstructed signal, that is, the added locally reconstructed signalfrom the adding part 15D is close to the acoustic signal accordingly,and the number of “0” bits in the error signal from the errorcalculating part 16 increases correspondingly. The combining part 320combines the perceptually optimized code Ina, the error minimized codeInp and the reversibly encoded code Ine.

[0229] In the decoder 20 the error minimized code Inp is irreversiblydecoded in an error minimized code decoding part 24A, and thereconstructed signal from the decoding part 24A and the reconstructedsignal from the perceptually optimized code decoding part 23 are addedtogether in an adding part 24B. The added signal is applied via theswitching part 28 to the adding part 27, wherein it is added to thereconstructed error signal from the reversible decoding part 26. Whenthe reversibly encoded code Ine is not input or when sufficientinformation for reconstructing the error signal is not available,switching part 28 applies the decoded signal of the perceptuallyoptimized code Ina as the reconstructed acoustic signal to the framecombining part 29 in place of the added decoded signal from the addingpart 24B. The error minimized code decoding part 45 and the adding part24B constitute the modifying part 24.

EMBODIMENT 9

[0230]FIG. 30 illustrates in block form a ninth embodiment of thepresent invention. This embodiment differs from the FIG. 27 embodimentin the construction of the modifying part 15 of the coder 10 and in theprovision of an error minimization coding part 19 and in thecorresponding modifications of the decoder 20.

[0231] In the coder 10 the acoustic signal for each frame is subjectedto irreversible compression coding in the error minimization coding part19 in such a manner as to minimize the energy of quantized error, andthe error minimized code Inp is output as the irreversibly encoded code.The error minimized code Inp is locally decoded in a local decoding part15E, and the locally reconstructed signal and that from the localdecoding part 14 are applied to a weighted averaging part 15F, whichobtains a weighted average of them placing emphasis on the former. Anerror between the weighted mean locally reconstructed signal and theacoustic signal is calculated in the error calculating part 16, and theerror signal is applied to the reversible coding part 18.

[0232] The weight in the weighted averaging part 15F is a statisticallypre-calculated value such that the error signal from the errorcalculating part 16 becomes small; it is set to, for example,approximately 0.8 to 0.9 for the locally reconstructed signal of theerror minimized code, and around 0.1 to 0.2 for the locallyreconstructed signal for the perceptually optimized code. Alternatively,the both locally reconstructed signals and the acoustic signal are inputto the modified parameter generating part 17, wherein both weights aredetermined by solving simultaneous equations so that the error signalfrom the error calculating part 16 becomes minimum. In this case, theboth weights are encoded and a weight code Inw is output. The localdecoding part 15E and the weighted averaging part 15F constitute themodifying part 15.

[0233] The combining part 320 combines the perceptually optimized codeIna, the error minimized code Inp and the reversibly encoded code Ine,and output a combined output. In case of using the modified parametergenerating part 17, the combining part 320 combines the weighted codeInw as well as the above-mentioned codes. The perceptual optimizationcoding part 13 and the error minimization coding part 19 may sometimesshare such parameters as the spectral envelope and power. In such case,as indicated by the broken lines, a common coding part 13A for encodinga parameter common to both of them is placed in the one coding part, inthe illustrated example, in the perceptual optimization coding part 13,and the common coding part 13A outputs the parameter as a common codeInc and provides, as required, the extracted common parameter to theother coding part, that is, in the error minimization coding part 19 inthis case. Moreover, a coding part 13B placed in the perceptualoptimization coding part 13 encodes, for example, waveform informationof the input acoustic signal by vector quantization taking theperceptual characteristics into account, and outputs a code Inar.Further, a coding part 19A in the error minimization coding part 19similarly encodes the waveform information of the acoustic signal as byvector quantization so as to minimize the energy of the quantized errorand outputs a code Inpr.

[0234] In the decoder 20 the error minimized code Inp separated in theseparation part 440 is irreversibly decoded in the error minimized codedecoding part 24A, and the decoded signal and the decoded signal fromthe perceptual optimization coding part 23 are applied to a weightedaveraging part 24C, which conducts a weighted addition biased toward theformer. The weighted signal is provided to the adding part 27, whereinit is added to the reconstructed error signal from the reversibledecoding part 21, and the added signal is applied via the switching part28 to the frame combining part 250. The weight in the weighted averagingpart 24C is set to the same weight as that in the weighted averagingpart 15F of the coder 10. When the weight is determined in the modifiedparameter generating part 17 of the coder 10, the weight code Inwseparated in the separation part 440 is decoded in a weight decodingpart 29, and the reconstructed weight is supplied to the weightedaveraging part 24C. The reconstructed signal of the perceptuallyoptimized code Ina and the reconstructed signal of the error minimizedcode Inp are applied to another weighted averaging part 26 as well,which obtains a weighted average biased toward the former (Ina decodedsignal). The weight for this weighted averaging is fixedly set to about0.8 to 0.9 for the Ina decoded signal and about 0.2 to 0.9 for the Inpdecoded signal. Alternatively, the weight reconstructed in the weightdecoding part 29 may be provided to the weighted averaging part 26 in arelation inverse to the weighting in the weighted averaging part 24C.

[0235] When the reversibly encoded code Ine is not input or whensufficient information for reconstructing the error signal in thereversible decoding part 21 is not available, the averaged decodedsignal from the weighted averaging part 26 is provided as areconstructed acoustic signal via the switching part 28 to the framecombining part 250. When the common code Inw is separated in theseparation part 440, it is decoded in a common decoding part 22. Acommon reconstructed signal is applied to the perceptual optimizationdecoding part 23 and the error minimized code decoding part 24A. Thesedecoding parts 23 and 24A are supplied with the codes Inar and Inpr,respectively, and provide desired decoded signals. The error minimizedcode decoding part 24A and the weighted averaging part 24C constitutethe modifying part 24.

EMBODIMENT 10

[0236]FIG. 31 illustrates in block form a tenth embodiment of thepresent invention, in which the parts corresponding to those in FIG. 30are identified by the same reference numerals. In the coder 10 of thisembodiment, the locally reconstructed signal for the error minimizedcode Imp is applied directly to the error calculating part 16 from thelocal decoding part 15E. Accordingly, the perceptually optimized codeIna is not locally decoded, but instead the result of local decoding ofthe error minimized code Inp is used for the error calculation in theerror calculating part 16. As the case with Embodiment 9, thisembodiment may also be adapted so that one of the perceptualoptimization coding part 13 and the error minimization coding part 19extracts parameters common to both of them for their coding and thatthey output the common code Inw and the codes Inar and Inpr of theirown.

[0237] In the decoder 20 the decoded signal from the error minimizedcode decoding part 24A is applied directly to the adding part 27,wherein it is added to the reconstructed error signal from thereversible decoding part 21. The switching part 28 switches between theperceptually optimized code decoding part 23 and the adding part 27 andapplies the reconstructed signal from the former or the added signalfrom the later as the reconstructed acoustic signal to the framecombining part 250. The operation in the case of the common code Incbeing separated in the separation part 440 is the same as describedpreviously with reference to FIG. 30.

EMBODIMENT 11

[0238]FIG. 32 illustrates in block form an eleventh embodiment of thepresent invention, in which the parts corresponding to those in FIG. 30are identified by the same reference numerals. In the coder 10 of thisembodiment: the perceptual optimization coding part 13 in the FIG. 30embodiment is connected to the output side of the error calculating part16; the error between the locally reconstructed signal of the errorminimized code Inp from the local decoding part 15E and the acousticsignal is calculated in the error calculating part 16; the error signalis subjected to lossy compression coding in the perceptual optimizationcoding part 13 in a manner to minimize perceptual distortion; and thislossy code is output as the perceptually optimized code Ina. In thecombining part 320 the error minimized code Inp, the perceptuallyoptimized code Ina and the lossless code Ine are combined, and thecombined output is provided.

[0239] In the decoder 20 the separated perceptually optimized code Inais subjected to lossy decoding in the perceptual optimization decodingpart 23, and this lossy decoded signal and the reconstructed signal ofthe error minimized code Inp by the error minimized code decoding part24A are added in an adding part 24B. The reconstructed signal of theerror minimized code Inp and the lossless reconstructed signal of thelossless code Ine, that is, the reconstructed error signal, are addedtogether in the adding part 27, from which the added signal is appliedas a reconstructed acoustic signal to the frame combining part 250 viathe switching part 28. When no error signal is reconstructed in thelossless decoding part 21, the added reconstructed signal from theadding part 24B is supplied as the reconstructed acoustic signal to theframe combining part 250 via the switching part 28.

[0240] This embodiment is also common to the eighth to tenth embodimentsin that the lossless coding part 18 uses, for the lossless compressioncoding, a quantization sequence which minimizes the energy of thequantized error and that when only information for the lossy compressioncoding is available, use is made of the result of quantization whichminimizes perceptual distortion. In this embodiment, however, thequantization for minimizing perceptual distortion is further carried outin the perceptual optimization coding part 13, that is, multi-stagequantization is performed. This increases the number of coded bits as awhole but achieves improvement in terms of auditory sensation andprovides increased efficiency in the optimization of distortion energy,too, as compared with the use of the locally reconstructed signal at thefirst stage, that is, the locally reconstructed signal of the errorminimized code Inp from the local decoding part 15E. For optimization ofdistortion energy, it is advisable to use the more efficient scheme.

[0241] The scheme in this case will be described below in respect of thebroken-lined configuration in FIG. 32. The code Ina from the perceptualoptimization coding part 13 is locally decoded in the local decodingpart 14, and the locally reconstructed signal is applied to an addingpart 31, wherein it is added to the code Inp from the local decodingpart 15E. The error between the added locally reconstructed signal andthe acoustic signal is calculated in an error calculating part 32. Theerror signal and the error signal from the error calculating part 16 arecompared in a comparison part 33, and the smaller one of them isselected in the select part 34 and supplied to the reversible codingpart 18. At this time, a select code Ins is output which indicates whichof the error signals has been selected.

[0242] In the decoder 20 a select part 41 is controlled by a selectsignal Ins separated in the separation part 440. When the error signalfrom the error calculating part 16 is selected in the coder 10, thereconstructed signal from the error minimized code decoding part 24A isselected and applied to the adding part 27. When the error signal fromthe error calculating part 32 is selected in the coder 10, the addedreconstructed signal from the adding part 24B is selected and applied tothe adding part 27.

[0243]FIG. 33 illustrates in block form a concrete example of thereversible coding part 18 used in FIGS. 27 to 32. The illustratedconfiguration is substantially the same as that shown in FIG. 14 whichis composed of the rearrangement part 160, the transmission/recordingunit separation part 310, the lossless coding part 150 and the auxiliaryinformation generating part 350. The error signal from the errorcalculating part 16 is applied to the rearrangement part 160 and theauxiliary information generating part 350. In the effective digit numberdetecting part 353 of the auxiliary information generating part 35 thedigit number, which represents the maximum value of the absolute valueof the error signal for each frame, is detected as the effective digitnumber Fe. As described previously with reference to FIGS. 15A and 15B,bits of respective samples (amplitude bit sequences) of the error signalat the bit positions common thereto, only in the portion or rangedefined by the effective digit number, are concatenated across the frameto form equi-position bit sequences.

[0244] The equi-position bit sequences from the rearrangement part 169are separated by the transmission/recording unit separating part 310 topieces of transmission unit or recording unit data. Each of theseparated pieces of transmission/recording unit data is, if necessary,subjected to lossless compression coding in the lossless coding part150, from which it is output as the error code Ine.

[0245] On the other hand, the effective digit number Fe detected in theeffective digit number detecting part 353 is provided to the auxiliaryinformation coding part 352. In this embodiment, the error signal samplesequence is provided to the spectral envelope calculating part 351,wherein it is subjected to, for example, linear prediction codinganalysis for each frame, and the spectral envelope parameters LPC areobtained as linear prediction coefficients. And the average power of theerror signal for each frame is calculated in the power calculating part354. Alternatively, the error signal is input to the inverse filter 355formed based on the linear prediction coefficients calculated in thespectral envelope calculating part 354, by which the spectral envelopeof the error signal is flattened, and the average power of the flattenedsignal is calculated in the power calculating part 356. These effectivedigit number Fe, linear prediction coefficients LPC and average powerare encoded with low bits, for example, approximately 30 to 50 bits inthe auxiliary information coding part 352, from which auxiliaryinformation Inx is provided. The auxiliary information Inx encoded fromthe effective digit number, the spectral envelope parameters and theaverage power is fed to the combining part 420 (FIGS. 27 and 29 to 32),wherein it is added to a representative packet of each frame or added ina packet having loaded therein the transmission/recording unit datacontaining the sign bit and from which it is output as such or as anindependent packet.

[0246]FIG. 34 illustrates in block form a concrete example of thelossless decoding part 21 of the decoder 20, together with theinformation correcting part 480. In the separating part 440 theauxiliary information Inx and the error code Ine are separated from theinput packet Pe. The error code Ine is provided to the lossless decodingpart 210, and the auxiliary information Inx is provided to the auxiliaryinformation decoding part 450. The auxiliary information decoding part45 decodes the effective digit number Fe, the spectral envelopecoefficients LPC and the average power of the frame concerned, andprovides the effective digit number Fe to the digit adjusting part 460and the spectral envelope parameters and the average power to themissing information compensating part 430. Since the operations of theserespective parts have already been described with reference to the FIG.14 embodiment, no description will be repeated.

[0247] The lossless coding part 18 of the coder 10 in the embodiments ofFIGS. 27 to 32 may also be adapted to further perform predictionprocessing for the error signal. An example of its configuration isshown in FIG. 35A. The error signal is applied to the spectral envelopecalculating part 351, which calculates the linear predictioncoefficients LPC representing the spectral envelope of the error signal.On the other hand, the error signal is applied to the prediction errorgenerating part 370, from which the prediction error signal Spe ifprovided. For example, a plurality of immediately preceding error signalsamples from the error calculating part 16 are supplied from theregister 371 to the linear prediction part 372, wherein they aremultiplied by the linear prediction coefficients LPC representing thespectral envelope from the spectral envelope calculating part 351 toobtain a linear prediction value. The linear prediction value is fed tothe integer part 373, wherein it is put to an integral value. Thedifference between the integral prediction value and the current sampleof the error signal from the error calculating part 16 is calculated inthe difference circuit 374 to obtain the prediction error signal Spe.The prediction error signal Spe is input to the rearrangement part 160.

[0248]FIG. 35B depicts an example of the configuration of the losslessdecoding part 21 of the decoder 20 in the case of applying the FIG. 35Aconfiguration to the lossless coding part 18 of the coder 10. Theillustrated configuration identical with that composed of therearrangement part 220, the missing information compensating part 430,the auxiliary information decoding part 450 and the synthesis filter 470in the decoder 20 shown in FIG. 21. The reconstructed prediction errorsignal Spe from the information correcting part 480 is applied to thesynthesis filter 470, wherein it is subjected to processing inverse tothat in the prediction error generating part 370 of the lossless codingpart 18 in FIG. 35A. That is, a predetermined constant number ofimmediately preceding reconstructed samples are input from the register471 to the linear prediction part 472, wherein they are respectivelymultiplied by weights based on the linear prediction coefficients LPCdecoded in the auxiliary information decoding part 450, and the sum ofthe results of multiplication is obtained as a predicted value of thecurrent decoded sample. The predicted value is put to an integral valuein the integer part 473. The integral predicted value and the currentprediction error signal from the information correcting part 480 areadded together in the adding part 474, whose output is used as theoutput fro the synthesis filter 470, that is, as the reconstructed errorsignal.

EMBODIMENT 12

[0249] While the embodiments described above are directed to the coderand the decoder for the one-channel digital input signal, the embodimentare applicable as well to multi channel signals. There have beendeveloped several compression coding schemes for multi-channel signals,such as AC-3 (Audio Coding by Dolby, Inc.etc.) and AAC (Advanced AudioCoding by Dolby, Inc.etc.) With these conventional schemes, perceptualdistortion can be reduced substantially but the waveform appreciablydiffers from that of the original waveform. When multi-channel signalsare transmitted intact in a PCM (Pulse Code Modulation) form, theoriginal sound can completely be reconstructed, but a large amount ofinformation is necessary. Further, no sound can be reconstructed by somepart of its code sequence, and on this account, in the case of packettransmission of the PCM signal, a packet erasure seriously contributesthe deterioration of the sound quality.

[0250] It is possible to enhance the coding efficiency by mixingmulti-channels signals to reduce the number of channels for coding. Inthis case, however, the original multi-channel signals cannot bereconstructed correctly.

[0251] This embodiment offers multi-channel signal coding and decodingmethods and a coder and a decoder therefor, which: mix digital signalsof plural channels and encode them into digital signals of a smallernumber of channels; increases the coding efficiency, enables originaldigital signals of plural channels to be reconstructed with highfidelity; permit selection of the bit rate over a wide range; and allowselection of the number of channels over a wide range.

[0252]FIG. 36 illustrates in block form a coder and°a decoder accordingto this embodiment. In the coder 10, digital signals of M (M being aninteger equal to or greater than 2) channels are input to the frameforming part 110 via terminals 100 ₁ to 100 _(M), wherein they areseparated for each frame, for example, every 1024 samples. The digitalsignals separated are applied to a signal mixing part 30, wherein theyare mixed with digital signals of M channels smaller in number than M. Nis an integer equal to or greater than 1, and N<M. The mixed N-channelsignals are subjected to lossy or lossless compression coding in acoding part 120, from which a main code Im is output. This coding maypreferably be high-compression-ratio coding. The main code Im is decodedin a local decoding part 130, from which a locally reconstructed signalis provided. This locally reconstructed signal is applied to a channelexpansion part 40, wherein it is converted to locally reconstructedsignals of the original M channels. This locally reconstructed signalsfor the code Im can be obtained in the coding part 120 due to itsanalysis-by-synthesis coding scheme.

[0253] In the signal mixing part 30 an average signal of those of firstfour of, for example, eight channels may be used as a left-channelsignal and an average signal of those of the other four channels may beused as a right-channel signal. Alternatively, an average signal oftwo-channel signals is used as a one-channel monaural signal.

[0254] In the channel expansion part 40 the locally reconstructed signalis converted to signals of the original channels. The locallyreconstructed signals of the increased number of channels have someinformation of the input digital signals lost due to reduction in thenumber of channels in the mixing part 30. The missing signals arecalculated as error signals in an error calculating part 134 which issupplied with the M-channel digital signals branched from the frameforming part 110 and the M-channel locally reconstructed signal. Theerror signals are applied to a bit sequence converting part 50, whereinthey are subjected to bit sequence rearrangement and compression coding,and from which an error code Ine and an auxiliary information code Inxare output. Although a concrete configuration and processing of the bitsequence converting part 50 will be described, it is equipped with atleast the rearrangement part 160 for conversion to equi-position bitsequences as described previously with reference to FIGS. 4A and FIGS.15A and 15B. The error code Ine and the auxiliary information Inx fromthe bit sequence converting part 50 and the main code Im from the codingpart 120 are combined in the combining part 320, from which the combinedoutput is provided. When the combined output is sent out as a packet Pe,it is added with the header 31 referred to previously in connection withFIG. 4B.

[0255] In the decoder 20 the input packet P2 is separated by theseparating part 440 to the main code Im, the error code Ine and theauxiliary information Inx in this case. The main code Im is decoded in adecoding part 60 by a decoding scheme corresponding to the coding schemeof the coding part 120 in the coder 10. The decoded signals from thedecoding part 120 are provided to a channel expansion part 80, whereinthey are converted from the N-channel decoded signals to M-channeldecoded signals.

[0256] The error code Ine is processed in a bit sequence inverseconversion part 70 to reconstruct the M-channel error signals. Althoughthe configuration and operation of the bit sequence inverse conversionpart 70 will be concretely described, it is equipped with at least therearrangement part 220 referred to previously with reference to FIGS.4A, 15A and 15B, and reconstructs error signals each composed ofamplitude bit sequences. The auxiliary information Inx is decoded in theinformation correcting part 440, and when a packet erasure is detectedin the erasure detecting part 420, the reconstructed error signal iscorrected in the information correcting part 480 based on the auxiliaryinformation.

[0257] The reconstructed M-channel error signals and the reconstructedsignals of increased M channels are added for channel in the adding part240, from which the added outputs are provided as reconstructed digitalsignals of M channels to the frame combining part 250, from whichframe-concatenated digital signals of the respective channels areoutput.

[0258] With the above-described configuration, when the main code Im,the error code Ine and the auxiliary information Inx are input to thedecoder 20 with erasure of a number small enough to obtain thereconstructed signal and the reconstructed error signal, the originalM-channel digital signals can be reconstructed with high fidelity. Thecoding efficiency can be changed, as required, by selecting the numberof channels to be decreased in the signal mixing part 30. When no packetis input or when no sufficient amount of information for reconstructingthe error signal is available, it is possible to obtain signals ofappreciable quality by applying the M-channel reconstructed signals asreconstructed digital signals to the frame combining part 250 from thechannel expansion part 80.

[0259] In the FIG. 36 embodiment the mixing operation in the signalmixing part 30 may be performed in a plurality of stages. An examplewill be described below with reference to FIG. 37, in which the partscorresponding to those in FIG. 36 are identified by the same referencenumerals. In this example, signal mixing takes place in two stage, thatis, in signal mixing parts 30 and 41. For instance, original M=8 channelstereo digital signals are mixed with N=2 channel or N=4 channel stereodigital signals, and the thus mixed stereo digital signals are mixedwith L=1 channel monaural digital signals. The mixed signal from thesignal mixing part 41 is encoded in the coding part 120, from which themain code Im is output.

[0260] The main code Im is reconstructed in the local decoding part 130,and the locally reconstructed signal is provided to the channelincreasing part 42, wherein it is converted from L to N channels. Theerror signal between the N-channel locally reconstructed signals and theN-channel digital signals from the signal mixing part 30 are calculatedin an error calculating part 120. The error signals are subjected tolossy or lossless, preferably, high-compression-ratio coding in a codingpart 44, from which they are output as a sub-code Ie.

[0261] The sub-code Ie is decoded in a local decoding part 45 intoN-channel locally reconstructed signals, which are added to theN-channel locally reconstructed signals from the signal mixing part 42in an adding part 46. The added N-channel locally reconstructed signalsare converted to M-channel added locally reconstructed signals in thechannel expansion part 40. Error signals between the M-channel addedlocally reconstructed signals and the M-channel digital signals from theframe forming part 110 are calculated in the error calculating part 140,from which the error signals are provided to the bit sequence convertingpart 50. The error code Ine and the auxiliary information Inx from thebit sequence converting part 50, the main code Im from the coding part120 and the sub-code Ie from the coding part 44 are combined in thecombining part 320, from which they are output as a packet.

[0262] In the decoder 20 the main code Im and the sub-code Ie separatedby the separating part 440 are reconstructed in decoding parts 60 and61, respectively, and the error code Ine is fed to the bit sequenceinverse conversion part 70, wherein it is inversely rearranged toreconstruct the error signals. The L-channel reconstructed signal fromthe decoding part 60 is converted to N-channel reconstructed signals inthe channel expansion part 80. The N-channel reconstructed signals andthe N-channel reconstructed signals from the decoding part 61 are addedtogether in an adding part 62. The N-channel added reconstructed signalsare converted to M-channel reconstructed signals in a channel increasingpart 63, and the N-channel reconstructed signals and the M-channel errorsignals are added together in the adding part 240, from whichreconstructed digital signals are applied to the frame combining part250.

[0263] In this instance, the bit rate can be chosen over anapproximately 60-fold range from 8 kbit/s to 5 Mbit/s.

[0264] In FIGS. 36 and 37, in the case of generating the packet Pe inthe combining part 320, it is preferable that the highest priority levelbe given to the packet containing the main code Im. The packetcontaining sub-code Ie is assigned the highest priority level next tothe packet containing the main code Im.

[0265] The lossless coding part 18 described previously with referenceto FIG. 33, for instance, can be used intact as the bit sequenceconverting part 50 in the coder 10. In such a case, the bit sequenceinverse conversion part 70 in the decoder 20 may be identical inconstruction with the lossless decoding part 21 described previously inrespect of FIG. 34, for example.

[0266] Alternatively, the lossless coding part 18 in FIG. 35A may beused as the bit sequence converting part 50. In this instance, the bitsequence inverse conversion part 70 in the decoder 20 may be identicalin construction with the lossless decoding part 21 in FIG. 25B, forinstance.

EMBODIMENT 13

[0267] When multi-channel signals are transmitted intact in PCM (PulseCode Modulation) form, the original sound can completely bereconstructed, but a large amount of information is necessary. Further,no sound can be reconstructed by some part of its code sequence, and onthis account, in the case of packet transmission of the PCM signal, apacket erasure contributes serious degradation of sound quality.

[0268] This embodiment is intended to offer coding and decoding methods,a coder and a decoder that make multi-channel digital signalsinsusceptible to the influence of information erasure and make itpossible to select the degree of information compression over arelatively wide range.

[0269] Turning to FIG. 38, a description will be given of the coder 10and decoder 20 according to this embodiment.

[0270] In the coder 10, M (where M is an integer equal to or greaterthan 2) digital signals are input via input terminals 100 ₁ to 100 _(M)to the frame forming part 110, wherein they are separated for eachframe, for example, every 1024 samples. These digital signals of every Mframes are subjected to inter-channel orthogonal transformation in aninter-channel orthogonal transform part 190, from whichorthogonal-transformed signals are provided. That is, samples of Mdigital signals at the same point in time are orthogonally transformed.When lossless transformation using an integral value is applied to theinter-channel orthogonal transformation, it is possible to achievelossless coding as a whole.

[0271] The orthogonal-transformed signals are input to the rearrangementpart 160. In the rearrangement part 160 the same bit positions (digits)of respective samples of each frame are arranged in a temporal order foreach component (for example, L+R and L−R) of the orthogonal-transformedsignals throughout the frame to form equi-position bit sequences).

[0272] The equi-position bit sequences from the rearrangement part 160are separated into pieces of transmission unit or recording unit data inthe transmission/recording unit separating part 310. These separatedpiece of transmission/recording unit data are, if necessary, subjectedto lossless coding in the lossless coding part 150, and in the combiningpart 320 they are added with a header so that during decoding theseparated pieces of transmission/recording unit data can bereconstructed as one frame, and they are provided as packets Pe to theoutput terminal 170. Incidentally, the coding in the lossless codingpart 150 is the same as the lossless coding in the prior art. In thecase of giving priorities to the packets Pe, they are assignedpriorities in descending order of the energy of the component of theorthogonal-transformed signal; for example, the packet containing thecomponent L+R is given the highest priority and the packets containingthe sign bit and the corresponding transmission/recording unit data onthe MSB side are higher priorities.

[0273] In the decoder 20, the packets Pe input thereto via the inputterminal 200, if containing auxiliary information, are each separated bythe separating part 440 to the auxiliary information, and thetransmission/recording unit data (containing the sign bit sequence). Thetransmission/recording unit data, if lossless-encoded, is provided tothe lossless decoding part 210, where it is lossless-decoded, thereafterbeing a transmission/recording unit assembling part 410. In thetransmission/recording unit assembling part 410, the pieces oftransmission/recording unit data of one frame are assembled from one ormore packets based on their packet numbers; they are assembled for eachcomponent of the orthogonal-transformed signals. The assembled data isprovided to the rearrangement part 220, wherein equi-position bitsequences are converted to amplitude bit sequences of one frame, thatis, sample sequences (waveform) of one component of theorthogonal-transformed signals. No description will be given of theoperations of the rearrangement parts 160 and 220 since they have beendescribed previously in detail with reference to FIGS. 4A, 15A and 15B.In the absence of a packet erasure, the rearrangement part 220 outputsorthogonal-transformed signals exactly identical with those input to therearrangement part 160 of the coder 10.

[0274] In an inter-channel inverse orthogonal transform part 290, eachcomponent of the input reconstructed orthogonal-transformed signals issubjected to transformation inverse to the orthogonal transformation inthe inter-channel orthogonal transform part 190, thereby reconstructingthe M-channel digital signals. The M-channel digital signalsreconstructed for each frame are successively outputted for each channelfrom the frame combining part 250, to output terminals 260 ₁ to 260_(M), respectively.

[0275] In this way, the M-channel digital signals can be transmitted orrecorded by their inter-channel orthogonal transformation. It ispossible to obtain reconstructed signals of relatively high quality by:packetizing in terms of transmission/recording unit; increasing priorityas the energy becomes larger or as MSB is approached; and using packetsof high priority when the channel capacity or storage capacity is small.Further, as described later on, compensation for information lost by apacket erasure permits reconstruction of multi-channel digital signalsof better quality.

[0276] In the above, the lossless coding part 150 and the losslessdecoding part 210 may be omitted.

EMBODIMENT 14

[0277] When such a transform scheme as DFT or DCT is used for theinter-channel orthogonal transform, the reconstructed digital signalsdiffer from the original digital signal even if orthogonal-transformedsignals are subjected to the inter-channel inverse orthogonal transform.Further, only part of orthogonal transform coefficient, that is, only acomponent of large energy, for example, only L+R, may sometimes berequired to output as a packet. This embodiment is intended to deal withthese problems.

[0278]FIG. 39 illustrates in block form a fourteenth embodiment of theinvention. This embodiment differs from the FIG. 39 embodiment in thatall or some components of the orthogonal-transformed signal from theinter-channel orthogonal transform part 190, that is, components oflarge power, are subjected to lossless coding in the coding part 120,from which the main code Im is output. The code from the coding part 120is decoded in a local decoding part 130 to generate a locallyreconstructed signal. The locally reconstructed signal for the code Imcan be obtained in the coding part 120 due to its analysis-by-synthesiscoding scheme. In an inter-channel orthogonal inverse transform part 180the locally reconstructed signal is transformed inversely to that in theinter-channel orthogonal transform part 190, by which digital locallyreconstructed signals of a plurality of channels are produced. Errorsignals between the locally reconstructed signals of the respectivechannels and the digital signals of the corresponding channels, whichare provided from the frame forming part 1 10, are calculated in theerror calculating part 140. In a bit sequence converting part 50 thecalculated error signals are subjected to processing of therearrangement part 160, the transmission/recording unit separating part310 and the lossless coding part 150.

[0279] The main code Im from the coding part 120 is separated by thetransmission/recording unit separating part 310 totransmission/recording unit, and in the combining part 250 thetransmission/recording unit and the error code Ine from the bit sequenceconverting part 50 are combined, and the combined output provided as thepacket Pe as required. Incidentally, the bit sequence converting part 50needs only to be provided with at least the rearrangement part 160 inFIG. 38 and needs not to perform the processing of thetransmission/recording unit separating part 310 and the lossless codingpart 150. In this case, the main code Im is not subjected to theprocessing of the transmission/recording unit separating part 310. Whenthe main code Im and the error code Ine are output as packets from thecombining part 320, the highest priority level is given to the packetcontaining the main code Im.

[0280] In the decoder 20, the main code Im and the error code Ine areseparated in the separating part 440. The main code Im is subjected tolossless decoding in the decoding part 60, and the reconstructed signalsare subjected to inter-channel orthogonal inverse transformation in theinter-channel orthogonal inverse transform part 290 through the sameprocessing as in that the inter-channel orthogonal inverse transformpart 180 of the coder 10.

[0281] On the other hand, the error code Ine is input to the bitsequence inverse conversion part 70, which performs the processing ofthe lossless decoding part 210, the transmission/recording unitassembling part 410 of the decoder 20 in FIG. 38, reconstructing theerror signal sample sequences. In this instance, however, it issufficient only to perform at least the processing in the rearrangementpart 220, and it is not always necessary to perform the processing ofthe lossless decoding 210 and the transmission/recording unit assemblingpart 410 in correspondence to the associated operations on the part ofthe coder 10.

[0282] These reconstructed error signals and the inversely transformedsignals from the inter-channel orthogonal inverse transform part 290 areadded for each channel in the adding part 240 to obtain reconstructeddigital signals of the respective channels, which are applied to theframe combining part 250.

[0283] Even if part of the components to be orthogonally transformed isomitted to reduce the number of coded bits with a view to implementingefficient coding, this embodiment permits reconstruction of the originaldigital signals. Further, when no error signal components are suppliedor even if no sufficient information for signal reconstruction isavailable, it is possible to obtain reconstructed signals of certainquality by using the inversely transformed signals from theinter-channel orthogonal inverse transform part 290 as digitalreconstructed digital signals. Various kinds of processing can beomitted in the bit sequence converting part 50, and the correspondingprocessing in the bit sequence inverse conversion part 70 can also beomitted. Moreover, the coding part 120 is not limited specifically tolossless coding but may also be adapted for lossy high-compression-ratiocoding. In such a case, the decoding part 60 in the decoder 20 is alsoadapted for lossy decoding. The high-compression-ratio coding can bedone using such methods as mentioned previously with reference to theprior art.

EMBODIMENT 15

[0284]FIG. 40 illustrates in block form a fifteenth embodiment of thepresent invention, in which the parts corresponding to those in FIG. 39are identified by the same reference numerals. The following descriptionwill be given of differences between the both embodiments.

[0285] In the coder 10, signals from the inter-channel orthogonaltransform part 190, wherein M-channel digital signals are subjected tointer-channel orthogonal transformation, are encoded in the coding part120, from which they are output as the main code Im. The main code Im islocally decoded in the local decoding part 130. The locallyreconstructed signal for the code Im can be obtained in the coding part120 due to its analysis-by-synthesis coding scheme. In this embodimentthe locally reconstructed signal is not subjected to inter-channelorthogonal inverse transformation. Instead, it is applied to the errorcalculating part 140, which calculates an error between each of theorthogonal-transformed signals from the inter-channel orthogonaltransform part 190 and the component of the main code Im correspondingto each transformed signal. The error signal is provided to the bitsequence converting part 50. Thereafter, the same processing as in thecoder of the FIG. 39 embodiment is carried out.

[0286] In the decoder 20, the main code Im reconstructed in the decodingpart 60 is provided to the adding part 240, wherein its main signals andthe error signals reconstructed in the bit sequence inverse conversionpart 70 are added. In the inter-channel orthogonal inverse transformpart 290 these added component signals are inversely transformedcorresponding to the in the inter-channel orthogonal transform part 190,from which reconstructed digital signals of respective channels areprovided to the frame combining part 250.

[0287] In this instance, too, correct reconstruction of the errorsignals permits faithfully reproduction of the multi-channel digitalsignals. As the case with Embodiment 14, this embodiment permitsenhancement of the coding efficiency by encoding in the coding part 120only a large-power component selected from the inter-channelorthogonal-transformed signals or predetermined therein on average. Thecoding in the coding part 120 may be either lossy high-compression-ratiocoding or lossless coding.

[0288] The bit sequence converting part 50 in FIGS. 39 and 40 may beidentical in construction with the lossless coding part 18 in FIG. 33,for instance. The bit sequence inverse conversion part 70 correspondingto the bit sequence converting part 50 may be identical in constructionwith the lossless decoding part 21.

[0289] Alternatively, the lossless coding part 18 in FIG. 35A may beused as the bit sequence converting part 50, and the lossless decodingpart 21 in FIG. 38B may be used as the bit sequence inverse conversionpart 70.

EMBODIMENT 16

[0290] With the above-described coding/decoding method intended forlossless coding by use of a lossy compressed code and a lossless code ofits error signal, the reconstructed signal of the lossy compressed codemay sometimes contain a very small error according to the environment ofa decoder or computer for reconstructing the lossy compressed code. Insuch a case, even if the reconstructed signal for the lossy compressedcode and the lossless code are combined with the reconstructed errorsignal in the decoder, the reconstructed digital signal will notcompletely match the original digital signal.

[0291] This embodiment is intended to provide coding and decodingmethods, a coder and a decoder which utilize lossy compression codingand lossless coding of its error signal and allow generation of areconstructed digital signal which theoretically completely matches theoriginal digital signal regardless of the use environment of the decoderor computer as will be described below with reference to FIG. 41.

[0292] In the coder 10 a digital signal from the input terminal 100 isseparated on a frame-by-frame, for example, every 1024 samples in theframe forming part 110, and the digital signal is encoded for each framein the lossy coding part 120, from which it is output as the main Im.The main code Im is reconstructed in the local decoding part 14, fromwhich is provided a locally reconstructed signal, which is applied to avarying maximum digit number detecting part 55 and a truncating part 56.The locally reconstructed signal for the code Im can be obtained in thelossy coding part 120 due to its analysis-by-synthesis coding scheme.The varying maximum digit number detecting part 55 detects, over oneframe or one or more sub-frames in the fame, the digit number thatassures the accuracy of the reconstructed signal of the main code Im,that is, the maximum of the digit number which varies with the decodingaccuracy of the decoder.

[0293] For example, in a decoder based on a coding scheme adapted inMPEG-4 audio standard, it is guaranteed independently of its useenvironment that each sample value of the reconstructed signal fallswithin the range of ±1 relative to a reference reconstructed signal.Accordingly, taking the local decoding part 14 into account, here is apossibility that the amplitudes of reconstructed signal by variousdecoder contains an error of ±2. The amplitude value of the locallyreconstructed signal in binary number format may sometimes vary up to ahigh-order digit number due to the above-mentioned ±1 error.

[0294] For example, when the amplitude of the locally reconstructedsignal is 8192 (0010000000000000 in binary number), it is consideredthat the reference decoded value is 8191 (0001111111111111 in binarynumber). Accordingly, in a different decoder, it is considered that theamplitude value varies from 8190 (0001111111110 in binary number) to8194 (0010000000000010 in binary number). In this case, the decodedvalue is guaranteed only at highest-order two digits even if the useenvironment is changed.

[0295] The maximum value of variable digit number herein mentionedrefers to the digit number over which the binary representation of theamplitude of a reconstructed waveform agrees with the waveform of theoriginal signal up to a specified digit number in one frame or one ormore sub-frames. When the above-said number 8192 is contained, themaximum digit number is 14. In the above numerical example, the minimumvalue of accuracy is highest-order two digits. In case of a negativenumber, the same processing as mentioned above is performed for theabsolute value. When the reconstructed amplitude is any one of −2, −1,0, 1 and 2, it is predetermined that all digits are 0s so as to preventpolarity inversion. The varying maximum digit number detecting part 55calculates the accuracy that is guaranteed for each sample of eachlocally reconstructed signal every frame or one or more sub-frames, thatis, calculates the amplitude value guaranteed to be reconstructed andobtains the minimum value of accuracy that is guaranteed every frame orone or more sub-frames, that is, the maximum value of the variable digitnumber as shown in FIG. 4.

[0296] The varying maximum digit number detecting part 55 calculates,for each sample of the locally reconstructed signal, the digit numbervariable according to environment as mentioned above, detects themaximum value of the variable digit number every frame of one or moreframes, and outputs it as a digit number code Ig, while at the same timethe truncating part 56 truncates the values equal to or smaller than themaximum value of the varying digit number, generating anaccuracy-guaranteed locally reconstructed signal. Theaccuracy-guaranteed locally reconstructed signal is such as indicated bythe line 11 defining the lower edge of the hatched portion in FIG. 42.

[0297] An error signal between the accuracy-guaranteed locallyreconstructed signal and the digital signal from the frame forming part110 is calculated in an error calculating part 16. The error signalbecomes the signal of that portion of the digital signal from the frameforming part 110 which underlies the accuracy-guaranteed locallyreconstructed signal line 11 in FIG. 42. The error signal is subjectedto lossless coding in a lossless coding part 18, from which it is outputas the error code Ine. The main code I,, the error code Ine and thedigit number code Ig are combined in the combining part 320, whosecombined output is provided to the output terminals 170.

[0298] In the decoder 20 the input code is separated for each frame bythe separating part 440 to the main code Im, the digit number code Igand the error code Ine. The main code Im is subjected to lossy decodingin the lossy decoding part 60, from which the reconstructed signal isprovided. The digit number code Ig is reconstructed in a digit numberdecoding part 81, from which the varying maximum digit number isobtained. A truncating part 82 truncates those value of the decodedsignal from the lossy decoding part 60 which are equal to or smallerthan the value of the varying maximum digit number and, outputs anaccuracy-guaranteed reconstructed signal.

[0299] The error signal Ine is lossless-reconstructed in the losslessdecoding part 21, by which the error signal is reconstructed. The errorsignal and the accuracy-guaranteed reconstructed signal from thetruncating part 82 are added together in the adding part 240, and theadded signal is applied as the reconstructed digital signal to the framecombining part 250, which sequentially combines the reconstructedsignals of the respective frame and provides the combined output to theoutput terminal 260.

[0300] As described above, the accuracy-guaranteed local signal producedin the coder 10 is kept unaffected by the worst total value of errorsthat occur in the local decoding part 14 and the decoder 20, and theaccuracy-guaranteed reconstructed signal produced in the decoder istheoretically in perfect agreement with the accuracy-guaranteed locallyreconstructed signal of the decoder. Accordingly, if the error signal iscorrectly reconstructed, it is possible to obtain a reconstructeddigital signal that is ideally in perfect agreement with the originaldigital signal. In this embodiment the digit number code Ig may also bean encoded version of the minimum value of accuracy.

EMBODIMENT 17

[0301] The varying maximum digit number, which is detected in thevarying maximum digit number detecting part 55, frequently becomes about3 or 4 bits when one sample is represented by 16 bits, for instance.With a sample of decoding accuracy at only high-order two digits as inthe afore-mentioned numeric example, the minimum value of accuracy, thatis the varying maximum digit number increases and the amplitude of theerror signal increases accordingly, and the number of bits of the errorcode Ine from the lossless coding part 18 increases, impairing thecoding efficiency. However, this occurs in the case where the samplevalue of the locally reconstructed signal is 1 only at one of high-orderdigits and 0 at all the other digits as in the afore-mentioned numericexample-the possibility of occurrence of such a phenomenon is remote.That is, excepting such exceptional samples, the minimum value ofaccuracy is about 12 or 13 bits as shown in FIG. 43A, for instance.

[0302] This embodiment is intended to produce such anaccuracy-guaranteed locally reconstructed signal as depicted in FIG. 43Aby encoding, every frame or one or more sub-frames: the minimum value ofaccuracy excepting exceptional samples, that is, the variable maximumdigit number; information about the positions (in the frame orsub-frame) of the exceptional samples; and their accuracy, that is, thevarying maximum digit number.

[0303] For example, as shown in FIG. 44 in which the parts correspondingto those in FIG. 41 are identified by the same reference numerals, inthe coder the locally reconstructed signal from the local decoding part14 is applied to an exception detecting part 57, which detects anexceptionally greatly varying digit number (exceptionally low accuracy)and provides the digit number (or accuracy) and the sample positioninformation to the varying maximum digit number detecting part 55 andthe truncating part 56, while at the same time encodes the variabledigit number (or accuracy) and the sample position information andoutputs them as an exception code Ige.

[0304] The varying maximum digit number detecting part 55 removes theexceptional samples from the locally reconstructed signal, then detectsthe varying maximum digit number (or accuracy minimum value) of theremoved locally reconstructed signal, and applies it to the truncatingpart 56, while at the same time encoding and outputting it as the digitnumber code Ig. The truncating part 56 truncates from the locallyreconstructed signal, for the exceptional sample, the value equal to orsmaller than the numerical value of its varying digit number and for theother portions the value equal to or smaller than the numerical value ofits varying maximum digit number, thereby providing the locallyreconstructed signal as an accuracy-guaranteed locally reconstructedsignal. The accuracy-guaranteed locally reconstructed signal is appliedto the error calculating part 16. The combining part 320 combines themain code Im, the error code Ine, the digit number code Ig and theexception code Ige as well and outputs the combined output. Thisembodiment is identical with the FIG. 41 embodiment except the above.

[0305] The exceptional samples are those samples in which is low in theaccuracy of the value of only a predetermined number of bits (large inthe variable digit number); alternatively, samples are selected in anascending order of accuracy of the values to a predetermined number ofbits (in ascending order of the variable digit number). In the combiningpart 320, as shown in FIG. 43B, for instance, a code indicating thenumber of exceptional sample, position information the exceptionalsamples and the exception code Ige representing the varying digit number(accuracy) are arranged in this order for each frame (or sub-frame) andthe digit number code Ig is added to the end of the arrangement, andthey are output as one block for each frame or sub-frame.

[0306] In the decoder 20 the separated exception code Ige is decoded inan exception decoding part 83, from which sample position informationand the variable digit number are obtained. The reconstructed signalfrom the lossy decoding part 60 is applied to a truncating part 82,which truncates values of the of sample indicated by the sample positioninformation from the exception decoding part 83, which is equal to orsmaller than the value equal to or smaller than the bit value of thevarying maximum digit number of the sample. As for the other samples,the values equal to or smaller than the bit values of the variablemaximum digit numbers indicated by the exception codes Ige decoded inthe exception decoding part 81 are truncated in the truncating part 82.As a result, an accuracy-guaranteed local signal is generated. Thisembodiment is identical with the FIG. 41 embodiment except the above.

[0307] This embodiment reduces the amount of information of the errorsignal in the coder 10, and hence enhances coding efficiency in thelossless coding part 18.

[0308] The lossless coding part 18 in FIGS. 41 and 44 may be of the sameconstruction as that of the lossless coding part 18 in FIG. 33, forinstance. In this case, the lossless decoding part 21 in the decoder 20may be of the same construction as that of the lossless decoding part 21in FIG. 34. Alternatively, the lossless coding part 18 in FIG. 35A maybe used intact as the lossless coding part 18, in which case thelossless decoding part 21 may use the configuration shown in FIG. 35B.

[0309] The coding and decoding method according to the above-describedembodiments of the present invention can be implemented by describingcomputer-executable programs on recording media and, as required,reading and executing them on a computer.

[0310] EFFECT OF THE INVENTION

[0311] As described above, according to the coding and decoding methodsof the first aspect of the present invention, corresponding bits of asequence of samples are successively obtained for each frame to generateequi-position bit sequences, which are output in a packet form, so thateven if a packet is erased during transmission, the erasure ofcorresponding bits of the sample sequence of the decoded frame does notseriously degrades the signal quality.

[0312] According to the coding and decoding methods of the second aspectof the present invention, the maximum digit number which varies based onthe accuracy of the decoder used is detected for each frame or sub-framein accordance with the accuracy of the reconstructed signal guaranteedby the decoder, and the values in a locally reconstructed signal whichare equal to or smaller than the bit value of its varying maximum digitvalue are truncated, by which an accuracy-guaranteed local signal isprovided, and an error signal between the local signal and the originaldigital signal is lossless-encoded. Accordingly, during decoding it ispossible to obtain an accuracy-guaranteed reconstructed signal which istheoretically in agreement with the accuracy-guaranteed digital signalfrom the coder, by truncating from the reconstructed signal of thelossless-code the values equal to or smaller than the bit value of thereconstructed varying maximum digit number.

[0313] As described above, the present invention can be recognized asthe following aspects:

[0314] 1st aspect: A coding method for encoding a digital signal foreach frame comprising a plurality of samples, comprising the steps of:

[0315] (a) generating multiple sets of data either consisting ofmultiple sets of lossless data of bits over said samples at each one ofbit positions of said digital signal in said frame or consisting oflossy data and lossless data of an error signal due to said lossy data;and

[0316] (b) outputting said multiple sets of data.

[0317] 2nd aspect: The coding method of 1st aspect, wherein said step(a) includes a step of converting an amplitude of each of said samplesto a binary format consisting of a sign bit and an absolute value priorto said lossless coding.

[0318] 3rd aspect: The coding method of 1st aspect, wherein said step(b) includes a step of forming a packet including said lossless codewith said header information, and outputting said packet.

[0319] 4th aspect: The coding method of 1st aspect, wherein said step(b) includes a step of assigning priorities to said bitstream in adescending order of significance of a sign bit and an absolute value.

[0320] 5th aspect: The coding method of 1st aspect, wherein said step(a) includes the step of:

[0321] (a-1) lossy coding of an original sound to generate lossycompression information and locally reconstructed signal; and

[0322] (a-2) performing said lossless coding of an error signal betweensaid locally reconstructed signal and said original signal as saiddigital signal; and

[0323] said step (b) outputs said lossy compression information togetherwith said lossless code.

[0324] 6th aspect: The coding method of 1st aspect, further comprising astep of calculating parameters representing a spectral envelope of saiddigital signal, encoding said parameters and outputting a code for saidparameters as auxiliary information together with said lossless code.

[0325] 7th aspect: The coding method of 1st aspect, wherein said step(a) comprises the steps of:

[0326] (a-1) determining, as a number of effective digits, a number ofdigits representing a maximum value of an absolute value of theamplitude of said digital signal in each frame; and

[0327] (a-2) forming at least one bitstream comprising bits of samplesof each frame at least every one bit position within said number ofdigits in a temporal order in said each frame as a pieces oftransmission/recording unit data as a part of said lossless code; and

[0328] said step (b) includes a step of outputting said number ofeffective digits together with said lossless code.

[0329] 8th aspect: The coding method of 7th aspect, wherein said step(b) includes a step of outputting said number of effective digits asauxiliary information, or said number of effective digits in any one ofpackets for said frame.

[0330] 9th aspect: The method of 6th aspect, wherein said step (a) ischaracterized by:

[0331] (a-1) calculating linear prediction coefficients as saidparameters, and a current predicted value based on the preceding digitalsignal; and

[0332] (a-2) subtracting said predicted value from the current sample toobtain a prediction error as said digital signal; and

[0333] said step (b) includes a step of outputting said linearprediction coefficients as auxiliary information together with saidlossless code.

[0334] 10th aspect: The coding method of 1st aspect, further comprisingthe steps of:

[0335] (0-1) lossy coding of an input signal for each frame, withrespect to a perceptual characteristics to a lossy compressed code andforming a locally reconstructed signal;

[0336] (0-2) generating a modified locally reconstructed signal bymodifying said locally reconstructed signal so as to reduce an errorbetween said locally reconstructed signal and said input signal; and

[0337] (0-3) generating an error signal between said input signal andsaid modified locally reconstructed signal as said digital signal.

[0338] 11th aspect: The coding method of 10th aspect, wherein said step(0-2) includes:

[0339] calculating modified parameters including a cross-correlationcomponent between said digital signal and said locally reconstructedsignal, and outputting a modified parameter code for said modifiedparameters; and

[0340] multiplying or convoluting said locally reconstructed signal bysaid modified parameter to generate said modified locally reconstructedsignal.

[0341] 12th aspect: The coding method of 10th aspect, wherein said step(0-2) includes the steps of:

[0342] multiplying said locally reconstructed signal by a modifiedparameter or combining a plurality of samples with modified parametersto generate said modified locally reconstructed signal; and

[0343] generating said modified parameter for each frame so that theenergy of said error signal is reduced.

[0344] 13th aspect: The coding method of 10th aspect, wherein said step(0-2) includes the steps of:

[0345] (0-2-1) calculating an error between said locally reconstructedsignal and said digital signal to generate an error signal;

[0346] (0-2-2) encoding said error signal, which minimizes aquantization error to an error minimized code, and generating a secondlocally reconstructed signal for said error minimized code; and

[0347] (0-2-3) adding said second locally reconstructed signal and saidlocally reconstructed signal to obtain said modified local signal.

[0348] 14th aspect: The coding method of 10th aspect, wherein said step(0-2) includes the steps of:

[0349] (0-2-1) encoding said digital signal, which minimizes aquantization error to an error minimized code to obtain a second locallyreconstructed signal for said error minimized code; and

[0350] (0-2-2) obtaining a linear combination of said locallyreconstructed signal and said second locally reconstructed signal withlarger coefficients for said locally reconstructed signal to calculatesaid modified local signal.

[0351] 15th aspect: The coding method of 1st aspect further comprisingthe steps of:

[0352] (0-1) lossy coding of an input signal for each frame, withrespect to a perceptual characteristics, and a first lossy compressedcode;

[0353] (0-2) lossy coding of said digital signal to a second lossycompressed code and a local signal for said second lossy compressedcode; and

[0354] (0-3) generating, as said digital signal, an error signal betweensaid local signal and said digital signal.

[0355] 16th aspect: The coding method of 1st aspect, further comprisingthe steps of:

[0356] (0-1) performing lossy compression coding of an input signal foreach frame to minimize a quantization error, and outputting an errorminimized code and generating for said error minimized code a firstlocally reconstructed signal;

[0357] (0-2) generating, as said digital signal, an error signal betweensaid first local signal and said input signal; and

[0358] (0-3) performing lossy coding of said error signal, with respectto a perceptual characteristics, and outputting a lossy compressed code.

[0359] 17th aspect: The coding method of 1st aspect, further comprisingthe steps of:

[0360] (0-1) mixing M-channel input signals into N-channel signals, saidM being an integer equal to or greater than 2 and said N being aninteger equal to or than 1 and equal to or smaller than said M;

[0361] (0-2) encoding said N-channel signals to generate a main code andN-channel locally reconstructed signals for said main code;

[0362] (0-3) transforming said N-channel locally reconstructed signalsinto M-channel locally reconstructed signals; and

[0363] (0-4) obtaining, as said digital signal, error signals betweeneach of said M-channel locally reconstructed signals and correspondingone of said M-channel input signals; and

[0364] said step (b) is a step of outputting said main code togetherwith said lossless code.

[0365] 18th aspect: The coding method of 16th aspect, further comprisingthe steps of:

[0366] (0-1) mixing said N-channel mixed signals into L-channel mixedsignals, said L being an integer equal to or greater than 1 and equal toor smaller than said N;

[0367] (0-2) encoding said L-channel mixed signals to generate said maincode and said L-channel locally reconstructed signals for said maincode;

[0368] (0-3) said L-channel locally reconstructed signals into N-channellocally reconstructed signals;

[0369] (0-4) calculating errors between said N-channel locallyreconstructed signals and said N-channel mixed signals as first errorsignals;

[0370] (0-5) encoding said first error signals to generate a sub-codeand N-channel locally reconstructed error signals for said sub-code;

[0371] (0-6) adding said N-channel locally reconstructed signals andsaid N-channel locally reconstructed error signals to generate N-channeladded locally reconstructed signals;

[0372] (0-7) transforming said N-channel added locally reconstructedsignals into said M-channel locally reconstructed signal; and

[0373] (0-8) generating, as said digital signal, second error signalsbetween each of said M-channel locally reconstructed signals andcorresponding one of said M-channel digital signals;

[0374] said step (b) includes a step of outputting said main code andsaid sub-code together with said lossless code and said main code.

[0375] 19th aspect: The coding method of 1st aspect, further comprisinga step of inter-channel orthogonal transforming M-channel input signalsinto orthogonal transform signals as said digital signal, said M beingan integer equal to or greater than 2, and said steps (a) and (b) beingperformed for each of said M channels.

[0376] 20th aspect: The coding method of 1st aspect, further comprisingthe steps of:

[0377] (0-1) inter-channel orthogonal transforming M-channel inputsignals into orthogonal transform signals, M being an integer equal toor greater than 2;

[0378] (0-2) encoding at least one part of said orthogonal transformsignals to generate a main code and locally reconstructed signals forsaid main code;

[0379] (0-3) inter-channel inverse orthogonal transforming said locallyreconstructed signals to M-channel locally reconstructed signals; and

[0380] (0-4) producing, as said digital signal to be lossless coded, anerror signal between each of said M-channel locally reconstructedsignals and corresponding one of said M-channel digital signals;

[0381] said step (b) includes a step of outputting said main codetogether with said lossless code.

[0382] 21st aspect: The coding method of 1st aspect, further comprisingthe steps of:

[0383] (0-1) inter-channel orthogonal transforming M-channel inputsignals to orthogonal transform signals, M being an integer equal to orgreater than 2;

[0384] (0-2) encoding at least one part of said orthogonal transformsignals to generate a main code and locally reconstructed signals forsaid main code; and

[0385] (0-3) producing, as said digital signal to be lossless coded, anerror signal between each of said locally reconstructed signals andcorresponding one of said orthogonal transform signals; and

[0386] said step (b) includes a step of outputting said main codetogether with said lossless code.

[0387] 22nd aspect: The coding method of 1st aspect, wherein said step(a) comprises the steps of:

[0388] (a-1) generating a lossy code and producing a locallyreconstructed signal by lossy coding of said digital signal;

[0389] (a-2) obtaining a maximum digit code for a maximum number ofvariable digits for each frame or subframe from said locallyreconstructed signal;

[0390] (a-3) generating an accuracy-guaranteed signal by omitting orrounding components equal to or less than said maximum number ofvariable digits from said locally reconstructed signal;

[0391] (a-4) generating an error signal between said accuracy-guaranteedlocally reconstructed signal and said digital signal; and

[0392] (a-5) lossless coding said error signal to said lossless code.

[0393] 23rd aspect: A decoding method which reconstructs a sequence ofsamples of a digital signal for each frame, comprising the steps of:

[0394] (a) decoding input codes to produce multiple sets of data eitherconsisting of multiple sets of lossless data of bits over said samplesat each one of bit positions of said digital signal in said frame orconsisting of lossy data and lossless data of an error signal due to thelossy data; and

[0395] (b) reconstructing a digital signal based on said multiple setsof data.

[0396] 24th aspect: The decoding method of 23rd aspect, wherein saidstep (b) includes a step of converting said sample sequences from abinary format consisting of a sign bit and an absolute value to a 2'scomplement format.

[0397] 25th aspect: The decoding method of 23rd aspect, wherein saidstep (b) includes a step of correcting said digital signal by smoothingsaid digital signal.

[0398] 26th aspect: The decoding method of 23rd aspect, wherein saidstep (b) includes a step of reconstructing the spectral envelope bydecoding an auxiliary information, and correcting said digital signal sothat a spectral envelope of said digital signal approximates saidreconstructed spectral envelope.

[0399] 27th aspect: The decoding method of 26th aspect, wherein saidstep (b) includes the steps of:

[0400] (b-1) substituting a provisional samples for missing or errorbits;

[0401] (b-2) calculating a spectral envelope of said provisionalsamples;

[0402] (b-3) normalizing the spectral envelope of said provisionalsamples by characteristics of said reconstructed spectral envelope orits modified spectral envelope; and

[0403] (b-4) producing restored samples by using said reconstructedspectral envelope or said modified spectral envelope and said flattenedspectral envelope.

[0404] 28th aspect: The decoding method of 26th aspect:, wherein saidstep (b) includes the steps of:

[0405] (b-1) substituting a provisional samples for missing or errorbits;

[0406] (b-2) calculating a spectral envelope of said provisionalsamples;

[0407] (b-3) calculating one spectral envelope by normalizing saidspectral envelope by said reconstructed spectral envelope or itsmodified spectral envelope; and

[0408] (b-4) restoring said provisional samples by use of said onespectral envelope.

[0409] 29th aspect: The decoding method of 27th aspect, wherein saidstep (b-3) includes steps of converting said calculated spectralenvelope to linear prediction cepstrum coefficients Ca, converting saidreconstructed spectral envelope to a linear prediction cepstrumcoefficients Cb or using reconstructed spectral envelope for saidauxiliary information, and calculating differences Cb−Ca between saidlinear prediction cepstrum coefficients Ca and Cb to obtain said onespectral envelope.

[0410] 30th aspect: The decoding method of any one of 27th, 28th and29th aspects, further comprising the step of:

[0411] (b-5) checking whether a distortion between the spectral envelopeof said provisional samples and said reconstructed spectral envelope iswithin a predetermined value;

[0412] setting said provisional samples as restored samples; and

[0413] if not within said predetermined value, repeating said steps(b-2), (b-3) and (b-4).

[0414] 31st aspect: The decoding method of 23rd aspect, wherein saidstep (a) includes a step of lossy-decoding lossy codes to locallyreconstructed signal, adding said locally reconstructed signal and saiddigital signal.

[0415] 32nd aspect: The decoding method of 23rd aspect, wherein saidstep (a) includes a step of decoding a piece of transmission/recordingunit data of said lossless code to at least one reconstructed bitstreamat least one bit position in said one frame based on said headerinformation; and

[0416] said step (b) includes a step of detecting an erasure or an errorfor said transmission/recording unit data and a step of adjusting digitsof said samples of said one frame in accordance with an input number ofeffective digits.

[0417] 33rd aspect: The decoding method of 32nd aspect, wherein saidstep (b) includes a step;

[0418] if the number of effective digits for a current frame is largerthan the number of effective digits for the one of preceding frames,downward shifting the samples in the preceding frames so that the numberof effective digits for the preceding frame equals to the number ofeffective digits for the current frame, and

[0419] if the number of effective digits for a current frame is smallerthan the number of effective digits for the one of preceding frames,upward shifting the samples in the preceding frame so that the number ofeffective digits for preceding frame equals to the number of effectivedigits for the current frame.

[0420] 34th aspect: The decoding method of 23rd aspect, wherein saidsamples are those of a prediction error signal, said method includingthe steps of:

[0421] (c) correcting the prediction error signal for an error or amissing unit data based on the spectral envelope of the prediction errorsignal;

[0422] (d) decoding input auxiliary information to linear predictioncoefficients; and

[0423] (e) synthesizing, based on linear prediction, a reconstructedoriginal signal from said prediction error signal and preceding samplesof said reconstructed original signal.

[0424] 35th aspect: The decoding method of 34th aspect, wherein saidstep (c) includes the steps of:

[0425] (c-1) substituting provisional samples for missing or error bits;

[0426] (c-2) calculating a spectral envelope of said provisionalsamples;

[0427] (c-3) calculating a flatness of said spectral envelope, and ifsaid flatness is within a predetermined value, setting said provisionalsamples as said prediction error signal;

[0428] (c-4) if said flatness is not within said predetermined value,normalizing said provisional samples by said spectral envelope or itsmodified spectral envelope waveform to obtain a normalized signal; and

[0429] (c-5) repeating said steps (c-1) to (c-4) using said normalizedsignal as said provisional samples.

[0430] 36th aspect: The decoding method of 34th aspect, wherein saidstep (c) includes the steps of:

[0431] (c-1) substituting provisional samples for missing or error bits;

[0432] (c-2) filtering said provisional samples by use of saidreconstructed linear prediction coefficients to generate a synthesizedsignal;

[0433] (c-3) calculating a spectral envelope of said synthesized signal;

[0434] (c-4) normalizing said provisional error signal by use of saidspectral envelope or its modified spectral envelope to obtain a spectrumflattened signal; and

[0435] (c-5) filtering said spectrum flattened signal by use of saidreconstructed linear prediction coefficients to reconstruct a predictionerror waveform.

[0436] 37th aspect: The decoding method of 34th aspect, wherein saidstep (c) includes the steps of:

[0437] (c-1) substituting provisional samples for missing or error bits;

[0438] (c-2) filtering said provisional samples by use of saidreconstructed linear prediction coefficients to generate a synthesizedsignal;

[0439] (c-3) calculating linear prediction coefficients of saidsynthesized signal;

[0440] (c-4) calculating linear prediction coefficients being acombination of an inverse characteristics of said calculated linearprediction coefficients or their band-enlarged linear predictioncoefficients, and said reconstructed linear prediction coefficients ortheir band-enlarged linear prediction coefficients; and

[0441] (c-5) filtering said provisional samples by use of said combinedlinear prediction coefficients to produce the prediction error signal.

[0442] 38th aspect: The decoding method of 36th or 37th aspect, furthercomprising the step of:

[0443] (f) checking whether a distortion between said calculated linearprediction coefficients and said reconstructed linear predictioncoefficients is within a predetermined value;

[0444] if within said predetermined value, setting the provisionalsamples as restored prediction error signal; and

[0445] if not within said predetermined value, repeating said steps(c-2) to (c-5) applying to said synthesized signal as said provisionalsamples.

[0446] 39th aspect: The decoding method of 31st aspect, furthercomprising the steps of:

[0447] (c) modifying said locally reconstructed signal by reducing anerror between said locally reconstructed signal and said digital signal,thereby generating a modified signal; and

[0448] (d) combining said modified decoded signal and said error signalto renew said reconstructed signal.

[0449] 40th aspect: The decoding method of 39th aspect, wherein saidstep (c) comprises the steps of:

[0450] (c-1) decoding a modified parameter code to a modified parameter;and

[0451] (c-2) multiplying or convoluting said locally reconstructedsignal by said modified parameter to obtain said modified signal.

[0452] 41st aspect: The decoding method of 39th aspect, wherein saidstep (c) comprises the steps of:

[0453] (c-1) multiplying or convolving said locally reconstructed signalby a modified parameter with at least one modified parameter to generatesaid modified signal; and

[0454] (c-2) generating said modified parameter so that the energy of anerror signal between said modified signal and said reconstructed signalreduces.

[0455] 42nd aspect: The decoding method of 23rd aspect, furthercomprising the steps of:

[0456] (c) lossy decoding an error minimized code to reconstruct a firstlocally reconstructed signal;

[0457] (d) adding said digital signal and said first locallyreconstructed signal to reconstruct a first digital signal;

[0458] (e) lossy decoding with respect to a perceptual characteristics asecond lossy code to reconstruct a second locally reconstructed signal;and

[0459] (f) outputting said first digital signal or said second digitalsignal.

[0460] 43rd aspect: The decoding method of 39th aspect, wherein saidstep (c) includes the steps of:

[0461] (c-1) decoding an error minimized code to a second locallyreconstructed signal; and

[0462] (c-2) adding said second locally reconstructed signal to saidlocally reconstructed signal to said modified signal.

[0463] 44th aspect: The decoding method of 39th aspect, wherein saidstep (c) includes the steps of:

[0464] (c-1) decoding an error minimized code to obtain a second locallyreconstructed signal; and

[0465] (c-2) weighted averaging of said second locally reconstructedsignal and said locally reconstructed signal with a larger weightingcoefficient for said second locally reconstructed signal than aweighting coefficient for said locally reconstructed signal.

[0466] 45th aspect: The decoding method of 23rd aspect, wherein saidsamples are M-channel error signals, said M being an integer equal to orgreater than 2, said decoding method further comprising the steps of:

[0467] (c) decoding an input main code to N-channel reconstructedsignals, said N being an integer equal to or smaller than said M andequal to or greater than 1;

[0468] (d) transforming said N-channel reconstructed signals intoM-channel reconstructed signals; and

[0469] (e) adding said M-channel error signals and said M-channelreconstructed signals to reconstruct M-channel digital signals.

[0470] 46th aspect: The decoding method of 23rd aspect, wherein saidsamples are M-channel error signals, said M being an integer equal to orgreater than 2, said decoding method further comprising the steps of:

[0471] (c) decoding an input main code to L-channel reconstructedsignals, said L being an integer equal to or greater than 1;

[0472] (d) transforming said L-channel reconstructed signals intoN-channel reconstructed main signals, said N being an integer equal orlarger than said L and equal to or smaller than said M;

[0473] (e) decoding a sub-code to N-channel reconstructed sub-signal;

[0474] (f) adding said N-channel reconstructed main signal and saidN-channel reconstructed sub-signals to generate N-channel added signals;

[0475] (g) transforming said N-channel added decoded signals toM-channel added signals; and

[0476] (h) adding said M-channel error signals and said M-channel addedsignals to reconstruct M-channel digital signals.

[0477] 47th aspect: The decoding method of 23rd aspect, wherein saidsamples are multi-channel samples, said decoding method furthercomprising the step of:

[0478] (c) inter-channel orthogonal inverse transforming saidmulti-channel samples to multi-channel digital signals.

[0479] 48th aspect: The decoding method of 23rd aspect, wherein saidsamples are M-channel error signals, said M being an integer equal to orgreater than 2, said decoding method further comprising the steps of:

[0480] (c) decoding an input main code to locally reconstructed signals;

[0481] (d) inter-channel orthogonal inverse transforming said locallyreconstructed signals to M-channel reconstructed signals; and

[0482] (e) adding said M-channel reconstructed signals and saidM-channel error signals to reconstruct M-channel digital signals.

[0483] 49th aspect: The decoding method of 23rd aspect, wherein saidsamples are M-channel error signals, said M being an integer equal to orgreater than 2, said decoding method further comprising the steps of:

[0484] (c) decoding an input main code to obtain M-channel locallyreconstructed signals;

[0485] (d) adding said M-channel locally reconstructed signals and saidM-channel error signals to reconstruct M-channel added signals; and

[0486] (e) inter-channel orthogonal inverse transforming said M-channeladded signals to reconstruct M-channel digital signals.

[0487] 50th aspect: The decoding method of 23rd aspect, furthercomprising the steps of:

[0488] (c) decoding a lossy code to produce a locally reconstructedsignal;

[0489] (d) decoding a maximum digit code to obtain a maximum number ofvariable digits;

[0490] (e) generating an accuracy-guaranteed signal by omitting orrounding components for equal to or less than said maximum number ofvariable digits from said locally reconstructed signal; and

[0491] (f) reconstructing a reconstructed signal by adding said digitalsignal and said accuracy-guaranteed signal.

[0492] 51st aspect: The decoding method of 50th aspect, wherein saidstep (d) includes a step of decoding an exceptional code to exceptionalvalues and their sample positions allocating said exceptional values oftheir sample positions of said accuracy-guaranteed signal.

[0493] 52nd aspect: A coder for coding a digital signal for each frame,comprising:

[0494] means for generating multiple sets of data either consisting ofmultiple sets of lossless data of bits over said samples at each one ofbit positions of said digital signal in said frame or consisting oflossy data and lossless data of an error signal due to said lossy; and

[0495] output means for outputting said multiple sets of data to producecodes.

[0496] 53rd aspect: The coder of 52nd aspect, further comprising:

[0497] a sign bit/absolute value converting part for converting anamplitude of each of samples to a binary format consisting of a sign bitand an absolute value, and for providing said converted sample to saidlossless coding means.

[0498] 54th aspect: The coder of 53rd aspect, wherein said output meansassigns priorities to said bitstream in a descending order ofsignificance of a sign bit and an absolute value.

[0499] 55th aspect: The coder of 52nd or 53rd aspect, furthercomprising:

[0500] a lossy coder for lossy-coding an original signal to producelossy compression information and locally reconstructed signal; and

[0501] an error calculating means for producing an error signal betweensaid locally reconstructed signal and said original signal as saiddigital signal;

[0502] wherein said output means outputs said lossy code together withsaid lossless code.

[0503] 56th aspect: The coder of 52nd, 53rd or 54th aspect, furthercomprising an auxiliary information generating part for encodingparameters representing a spectral envelope of said digital signal, forencoding said parameters and for outputting a code for said parameter asauxiliary information together with said lossless code.

[0504] 57th aspect: The coder of 52nd aspect, which further comprisesauxiliary information generating part for obtaining and outputting, asan effective digit number, a number of digits representing a maximumvalue of an absolute value of the amplitude of said digital signal ofeach frame, and wherein said lossless coding means generates, for saideach frame, said lossless code corresponding to the bitstream withinsaid effective digits.

[0505] 58th aspect: The coder of 52nd aspect, further comprising:

[0506] a spectral envelope calculating part for calculating linearprediction coefficients representing a spectral envelope of an inputsignal for each frame;

[0507] an auxiliary information generating part for encoding said linearprediction coefficients as auxiliary information;

[0508] a predicting part for calculating, for each frame, an integralprediction value of the current input signal from the digital signal andlinear prediction coefficients of the preceding frame; and

[0509] a prediction error generating part for subtracting said predictedvalue from the current input digital signal to obtain, as said digitalsignal to be lossless coded, a prediction error signal.

[0510] 59th aspect: The coder of 58th aspect, which further comprises aneffective digit number detecting part for obtaining, as a number ofeffective digits, a digit number representing a maximum value ofabsolute values of said digital siganl and adjoining said number ofeffective digits to said auxiliary information, and wherein saidlossless coding means generates, for each frame, said lossless codecorresponding to the bitstream within said effective digits.

[0511] 60th aspect: The coder of 52nd aspect, further comprising:

[0512] a lossy coding part for lossy coding of an input signal for eachframe, with respect to a perceptual characteristics to a lossycompressed code and forming a locally reconstructed signal;

[0513] a modifying part supplied with said locally reconstructed signal,for modifying said locally reconstructed signal so as to reduce an errorbetween said locally reconstructed signal and said input signal; and

[0514] an error calculating part supplied with said input signal andsaid modified locally reconstructed signal, for generating an errorsignal between said input signal and said modified locally reconstructedsignal as said digital signal.

[0515] 61st aspect: The coder of 52nd aspect, further comprising:

[0516] a channel mixing part supplied with M-channel input signals, formixing said M-channel input signals into N-channel signals, said N beingan integer equal to or larger than 1 and equal to or smaller than saidM, and M being an integer equal to or greater than 2;

[0517] coding part, supplied with said N-channel mixed signals, forencoding said N-channel signals to generating a main code, and N-channellocally reconstructed signals for said main code;

[0518] a channel expanding part supplied with said N-channel locallyreconstructed signals, for transforming said N-channel locallyreconstructed signals into M-channel locally reconstructed signals;

[0519] an error calculating part for producing, as said digital signal,error signals between said M-channel locally reconstructed signals andsaid M-channel input signals; and

[0520] wherein said output means outputs said main code together withsaid lossless code.

[0521] 62nd aspect: The coder of 52nd aspect, further comprising:

[0522] an inter-channel orthogonal transform part for transformingM-channel input signals into orthogonal transform signals, M being aninteger equal to or greater than 2;

[0523] coding part for coding at least one part of said orthogonaltransform signals to generate a main code and locally reconstructedsignals;

[0524] an inter-channel orthogonal inverse transform part fortransforming said locally reconstructed signals, to M-channel locallyreconstructed signals; and

[0525] an error calculating part for producing an error signal betweeneach of said M-channel locally reconstructed signals and correspondingone of said M-channel input signals each as said digital signal to belossless coded; and

[0526] wherein said output means outputs said main code together withsaid lossless codes.

[0527] 63rd aspect: The coder of 52nd aspect, further comprising:

[0528] an inter-channel orthogonal transform part for transformingM-channel input signals into orthogonal transform signals, M being aninteger equal to or greater than 2;

[0529] coding part for coding at least one part of said orthogonaltransform signals, to generate a main code and locally reconstructedsignals; and

[0530] an error calculating part for producing an error signal betweeneach of said locally reconstructed signals and corresponding one of saidorthogonal transform signals each as said digital signal to be losslesscoded; and

[0531] wherein said output means outputs said main code together withsaid lossless code.

[0532] 64th aspect: The coder of 52nd aspect, further comprising:

[0533] a lossy coding part for lossy coding an input signal to produce alossy code;

[0534] a local reconstructing part for producing, from said lossy code,a locally reconstructed signal;

[0535] a maximum variable digits number detecting part for detectingfrom said locally reconstructed signal a maximum number of variabledigits for each frame or one or more sub-frames and producing a maximumdigit code representing said maximum number of variable digits;

[0536] a truncating part for truncating or rounding components equal toor smaller than said maximum number of variable digits from said locallyreconstructed signal to generate an accuracy-guaranteed locallyreconstructed signal;

[0537] an error calculating part for generating, as said digital signalto be lossless coded, an error signal between said accuracy-guaranteedlocally reconstructed signal and said input signal; and

[0538] wherein said output means outputs said maximum number code andsaid lossy code together with said lossless code.

[0539] 65th aspect: A decoder which reconstructs a sequence of samplesof a digital signal for each frame, comprising:

[0540] means for decoding input codes to produce multiple sets of dataeither consisting of multiple sets of lossless data of bits over saidsamples at each one of bit positions of said digital signal in saidframe or consisting of lossy data and lossless data of an error signaldue to the lossy data; and

[0541] means for reconstructing a digital signal based on said multiplesets of data.

[0542] 66th aspect: The decoder of 65th aspect, further comprising:

[0543] a 2's complement converting part for converting each of saidsamples from a binary format consisting of a sign bit and an absolutevalue to 2's complement format to provide said samples.

[0544] 67th aspect: The decoder of 65th or 66th aspect, furtherincluding:

[0545] a missing information compensating part for estimating missingbitstreams from known information, and correcting said sample sequences.

[0546] 68th aspect: The decoder of 67th aspect, wherein said missinginformation compensating part comprises a low-pass filter for smoothingsaid sample sequences input thereto.

[0547] 69th aspect: The decoder of 67th aspect, which further comprisesan auxiliary information decoding part for decoding auxiliaryinformation input thereto to obtain a spectral envelope; and

[0548] wherein said missing information compensating part corrects saidsample sequences so that their spectral envelope approaches said decodedspectral envelope.

[0549] 70th aspect: The decoder of 69th aspect, wherein said missinginformation compensating part comprises:

[0550] a provisional samples generating part for substitutingprovisional samples for missing or error bits over samples;

[0551] a spectral envelope calculating part for calculating a spectralenvelope of said provisional samples:

[0552] an inverse filter for normalizing the spectral envelope of saidprovisional samples by characteristics of said reconstructed spectralenvelope or its modified spectral envelope;

[0553] a synthesis filter for producing a restored samples by using saidreconstructed spectral envelope or said modified spectral envelope andsaid flattened spectral envelope.

[0554] 71st aspect: The decoder of 69th aspect, wherein said missinginformation compensating part comprises:

[0555] a provisional waveform generating part for substitutingprovisional samples for missing or error bits;

[0556] a spectral envelope calculating part for calculating the spectralenvelope of said provisional samples;

[0557] a composite spectral envelope calculating part for calculatinglinear prediction coefficients of a combination of inversecharacteristics of said calculated spectral envelope or its modifiedspectral envelope and coefficients of reconstructed spectral envelope orits modified one;

[0558] a synthesis filter for reconstructing said provisional samples byuse of said composite spectral envelope.

[0559] 72nd aspect: The decoder of 71st aspect, wherein said compositespectral envelope calculating part comprises:

[0560] a first coefficient converting part for converting saidcalculated spectral envelope to linear prediction cepstrum coefficientsCa;

[0561] a second coefficient converting part for converting saidreconstructed spectral envelope to linear prediction cepstrumcoefficients Cb or using reconstructed envelope for said auxiliaryinformation;

[0562] a subtracting part for calculating differences Cb−Ca between saidlinear prediction cepstrum coefficients Ca and Cb; and

[0563] an inverse conversion part for inversely converting saiddifference Cb−Ca to obtain said linear prediction coefficients ofcomposite spectral envelope.

[0564] 73rd aspect: The decoder of 70th or 71st aspect, furthercomprising an error calculating part for:

[0565] calculating a distortion difference between the spectral envelopeof said provisional samples or restored samples and said reconstructedspectral envelope, setting said provisional samples as restored samples;and

[0566] if not within said predetermined value, supplying saidprovisional or restored samples to said inverse filter or said synthesisfilter.

[0567] 74th aspect: The decoder of 65th aspect, further comprising:

[0568] a lossy decoding part for lossy decoding lossy-codes to locallyreconstructed signal; and

[0569] adding part for adding said locally reconstructed signal to saiddigital signal.

[0570] 75th aspect: The decoder of 65th aspect, further comprising: anauxiliary information decoding part for decoding input auxiliaryinformation to obtain an effective digit for each frame; and a digitadjusting part for adjusting digits of said samples of said one frame orsaid restored samples in accordance with the number of effective digits.

[0571] 76th aspect: The decoder of 75th aspect, wherein said auxiliaryinformation decoding part is to decode average power as well, and saidmissing information compensating part is to correct the amplitudes ofsaid samples sequences as well by use of said decoded average power.

[0572] 77th aspect: The decoder of 65th aspect, wherein linearprediction of said samples are those of a prediction error signal, saiddecoder further comprises:

[0573] an auxiliary information decoding part for decoding inputauxiliary information to linear prediction coefficients;

[0574] a combining part for synthesizing reconstructed original signalfrom said prediction error signal and preceding samples of reconstructedoriginal signal by use of said linear prediction coefficients; and

[0575] a missing information compensating part for correcting theprediction error signal for an error or missing unit data based on thespectral envelope of the prediction error signal.

[0576] 78th aspect: The decoder of 77th aspect, wherein said missinginformation compensating part comprises:

[0577] a provisional waveform generating part for substituting aprovisional samples missing or error bits;

[0578] a spectral envelope calculating part for calculating the spectralenvelope of said provisional samples;

[0579] a flatness deciding part for calculating a flatness of saidspectral envelope, and if said flatness is within a predetermined value,setting said provisional samples as said prediction error signal; and

[0580] an inverse filter for normalizing said provisional samples bysaid spectral envelope or modified spectral envelope waveform to obtaina normalized signals if said flatness is not within said predeterminedvalue.

[0581] 79th aspect: The decoder of 77th aspect, wherein said missinginformation compensating part comprises:

[0582] a provisional waveform generating part for substitutingprovisional samples for missing or error bits;

[0583] a first synthesis filter for filtering said provisional samplesby use of said reconstructed linear prediction coefficients to generatea synthesized signal;

[0584] a spectral envelope calculating part for calculating a spectralenvelope of said synthesized signal;

[0585] a synthetic spectral envelope calculating part for calculatinglinear prediction coefficients being is a combination of inversecharacteristics of said calculated linear prediction coefficients ortheir band-enlarged linear prediction coefficients and saidreconstructed linear prediction coefficients or their band-enlargedlinear prediction coefficients; and

[0586] a second synthesis filter for filtering said provisional samplesby use of said combined linear prediction coefficients to produce theprediction error signal.

[0587] 80th aspect: The decoder of 74th aspect, which further comprises:

[0588] a modifying part for modifying said locally reconstructed signalby reducing an error between said locally reconstructed signal and saiddigital signal, thereby generating a modified signal; and

[0589] an adding part for combining said modified signal and said errorsignal to renew said reconstructed signal.

[0590] 81st aspect: The decoder of 65th aspect, wherein saidrearrangement part reconstructs M-channel error signals, said M being aninteger equal to or greater than 2, said decoder further comprising:

[0591] a decoding part for decoding a main code to N-channelreconstructed signals, said N being an integer equal to or greater than1 and equal to or smaller than said M;

[0592] a channel expansion part for transforming said N-channelreconstructed signals into M-channel reconstructed signals;

[0593] a erasure detecting part for detecting erasure bit and outputtingan erasure signal, said information correcting part having a missinginformation compensating part for adding missing information to thewaveform of said error signal corresponding to the erasure bit detectedby said erasure detecting part; and

[0594] an adding part for adding said M-channel error signals orcorrected error signals and said M-channel reconstructed signals togenerate M-channel digital signals.

[0595] 82nd aspect: The decoder of 65th aspect, wherein M rearrangementparts are provided in correspondence to M channels, for outputtingM-channel error signals, said M being an integer equal to or greaterthan 2, said decoder further comprising:

[0596] a decoding part for decoding a main code to locally reconstructedsignals;

[0597] an inter-channel orthogonal inverse transform part forinter-channel orthogonal inverse transforming said locally reconstructedsignals to M-channel reconstructed signals; and

[0598] an adding part for adding said M-channel reconstructed signalsand said M-channel error signals to reconstruct M-channel digitalsignals.

[0599] 83rd aspect: The decoder of 65th aspect, wherein M rearrangementparts are provided in correspondence to M channels, for outputtingM-channel error signals, said M being an integer equal to or greaterthan 2, said decoder further comprising:

[0600] a decoding part for decoding a main code to M-channel locallyreconstructed signals;

[0601] an adding part for adding said M-channel locally reconstructedsignals and said M-channel error signals to reconstruct M-channel addedsignal; and

[0602] an inter-channel orthogonal inverse transform part forinter-channel orthogonal inverse transforming said M-channel addedsignals to reconstruct M-channel digital signals.

[0603] 84th aspect: The decoder of 65th aspect, further comprising:

[0604] a lossy decoding part for decoding lossy code to produce alocally reconstructed signal;

[0605] a digit number decoding part for decoding a maximum digit code toobtain a maximum number of variable digits;

[0606] a truncating part for truncating components equal to or smallerthan said maximum number of variable digits from said locallyreconstructed signal to generate an accuracy-guaranteed signal; and

[0607] an adding part for adding together said digital signal and saidaccuracy-guaranteed signal to obtain a reconstructed signal.

[0608] 85th aspect: A coding program for implementing said codingmethods of 1st to 22nd aspects on a computer.

[0609] 86th aspect: A decoding program for implementing said codingmethods of 23rd to 51st aspects on a computer.

What is claimed is:
 1. A coding method for encoding a digital signal foreach frame comprising a plurality of samples, comprising the steps of:(a) generating multiple sets of data either consisting of multiple setsof lossless data of bits over said samples at each one of bit positionsof said digital signal in said frame or consisting of lossy data andlossless data of an error signal due to said lossy data; and (b)outputting said multiple sets of data.
 2. The coding method of claim 1,wherein said step (b) includes a step of assigning priorities to saidbitstream in a descending order of significance of a sign bit and anabsolute value.
 3. The coding method of claim 1, wherein said step (a)includes the step of: (a-1) lossy coding of an original sound togenerate lossy compression information and locally reconstructed signal;and (a-2) performing said lossless coding of an error signal betweensaid locally reconstructed signal and said original signal as saiddigital signal; and said step (b) outputs said lossy compressioninformation together with said lossless code.
 4. The coding method ofclaim 1, further comprising a step of calculating parametersrepresenting a spectral envelope of said digital signal, encoding saidparameters and outputting a code for said parameters as auxiliaryinformation together with said lossless code.
 5. The coding method ofclaim 1, wherein said step (a) comprises the steps of: (a-1)determining, as a number of effective digits, a number of digitsrepresenting a maximum value of an absolute value of the amplitude ofsaid digital signal in each frame; and (a-2) forming at least one bitstream comprising bits of samples of each frame at least every one bitposition within said number of digits in a temporal order in said eachframe as a pieces of transmission/recording unit data as a part of saidlossless code; and said step (b) includes a step of outputting saidnumber of effective digits together with said lossless code.
 6. Themethod of claim 4, wherein said step (a) is characterized by: (a-1)calculating linear prediction coefficients as said parameters, and acurrent predicted value based on the preceding digital signal; and (a-2)subtracting said predicted value from the current sample to obtain aprediction error as said digital signal; and said step (b) includes astep of outputting said linear prediction coefficients as auxiliaryinformation together with said lossless code.
 7. The coding method ofclaim 1, further comprising the steps of: (0-1) lossy coding of an inputsignal for each frame, with respect to a perceptual characteristics to alossy compressed code and forming a locally reconstructed signal; (0-2)generating a modified locally reconstructed signal by modifying saidlocally reconstructed signal so as to reduce an error between saidlocally reconstructed signal and said input signal; and (0-3) generatingan error signal between said input signal and said modified locallyreconstructed signal as said digital signal.
 8. The coding method ofclaim 1, further comprising the steps of: (0-1) performing lossycompression coding of an input signal for each frame to minimize aquantization error, and outputting an error minimized code andgenerating for said error minimized code a first locally reconstructedsignal; (0-2) generating, as said digital signal, an error signalbetween said first local signal and said input signal; and (0-3)performing lossy coding of said error signal, with respect to aperceptual characteristics, and outputting a lossy compressed code. 9.The coding method of claim 1, further comprising the steps of: (0-1)mixing M-channel input signals into N-channel signals, said M being aninteger equal to or greater than 2 and said N being an integer equal toor than 1 and equal to or smaller than said M; (0-2) encoding saidN-channel signals to generate a main code and N-channel locallyreconstructed signals for said main code; (0-3) transforming saidN-channel locally reconstructed signals into M-channel locallyreconstructed signals; and (0-4) obtaining, as said digital signal,error signals between each of said M-channel locally reconstructedsignals and corresponding one of said M-channel input signals; and saidstep (b) is a step of outputting said main code together with saidlossless code.
 10. A decoding method which reconstructs a sequence ofsamples of a digital signal for each frame, comprising the steps of: (a)decoding input codes to produce multiple sets of data either consistingof multiple sets of lossless data of bits over said samples at each oneof bit positions of said digital signal in said frame or consisting oflossy data and lossless data of an error signal due to the lossy data;and (b) reconstructing a digital signal based on said multiple sets ofdata.
 11. A coder for coding a digital signal for each frame,comprising: means for generating multiple sets of data either consistingof multiple sets of lossless data of bits over said samples at each oneof bit positions of said digital signal in said frame or consisting oflossy data and lossless data of an error signal due to said lossy; andoutput means for outputting said multiple sets of data to produce codes.12. The coder according to claim 11, wherein said output means assignspriorities to said bitstream in a descending order of significance of asign bit and an absolute value.
 13. The coder according to claim 1,further comprising: a lossy coder for lossy-coding an original signal toproduce lossy compression information and locally reconstructed signal;and an error calculating means for producing an error signal betweensaid locally reconstructed signal and said original signal as saiddigital signal; and wherein said output means outputs said lossy codetogether with said lossless code.
 14. The coder according to claim 11,further comprising an auxiliary information generating part for encodingparameters representing a spectral envelope of said digital signal, forencoding said parameters and for outputting a code for said parameter asauxiliary information together with said lossless code.
 15. The coderaccording to claim 11, which further comprises auxiliary informationgenerating part for obtaining and outputting, as an effective digitnumber, a number of digits representing a maximum value of an absolutevalue of the amplitude of said digital signal of each frame, and whereinsaid lossless coding means generates, for said each frame, said losslesscode corresponding to the bitstream within said effective digits. 16.The coder according to claim 11, further comprising: a spectral envelopecalculating part for calculating linear prediction coefficientsrepresenting a spectral envelope of an input signal for each frame; anauxiliary information generating part for encoding said linearprediction coefficients as auxiliary information; a predicting part forcalculating, for each frame, an integral prediction value of the currentinput signal from the digital signal and linear prediction coefficientsof the preceding frame; and a prediction error generating part forsubtracting said predicted value from the current input digital signalto obtain, as said digital signal to be lossless coded, a predictionerror signal.
 17. The coder according to claim 11, further comprising: alossy coding part for lossy coding of an input signal for each frame,with respect to a perceptual characteristics to a lossy compressed codeand forming a locally reconstructed signal; a modifying part suppliedwith said locally reconstructed signal, for modifying said locallyreconstructed signal so as to reduce an error between said locallyreconstructed signal and said input signal; and an error calculatingpart supplied with said input signal and said modified locallyreconstructed signal, for generating an error signal between said inputsignal and said modified locally reconstructed signal as said digitalsignal.
 18. The coder according to claim 11, further comprising: achannel mixing part supplied with M-channel input signals, for mixingsaid M-channel input signals into N-channel signals, said N being aninteger equal to or larger than 1 and equal to or smaller than said M,and M being an integer equal to or greater than 2; coding part, suppliedwith said N-channel mixed signals, for encoding said N-channel signalsto generating a main code, and N-channel locally reconstructed signalsfor said main code; a channel expanding part supplied with saidN-channel locally reconstructed signals, for transforming said N-channellocally reconstructed signals into M-channel locally reconstructedsignals; and an error calculating part for producing, as said digitalsignal, error signals between said M-channel locally reconstructedsignals and said M-channel input signals; and wherein said output meansoutputs said main code together with said lossless code.
 19. A decoderwhich reconstructs a sequence of samples of a digital signal for eachframe, comprising: means for decoding input codes to produce multiplesets of data either consisting of multiple sets of lossless data of bitsover said samples at each one of bit positions of said digital signal insaid frame or consisting of lossy data and lossless data of an errorsignal due to the lossy data; and means for reconstructing a digitalsignal based on said multiple sets of data.